git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Thomas Rast <trast@student.ethz.ch>
To: Jonathan Nieder <jrnieder@gmail.com>
Cc: Geoff Russell <geoffrey.russell@gmail.com>, <git@vger.kernel.org>,
	Michael J Gruber <git@drmicha.warpmail.net>
Subject: Re: git pull (Re: need advice on usage patterns)
Date: Mon, 26 Jul 2010 09:16:27 +0200	[thread overview]
Message-ID: <201007260916.27306.trast@student.ethz.ch> (raw)
In-Reply-To: <20100726033634.GA30877@burratino>

Jonathan Nieder wrote:
> +Incorporates changes from a remote repository into the current
> +branch.  In its default mode, a `git pull` is shorthand for
> +`git fetch` followed by `git merge FETCH_HEAD`.

In my ears, "a `git pull` is..." sounds weird.  I would remove the
'a'.  But maybe it's just my non-native English hard(ly) at work...

> -*Warning*: Running 'git pull' (actually, the underlying 'git merge')
> -with uncommitted changes is discouraged: while possible, it leaves you
> -in a state that is hard to back out of in the case of a conflict.
[...]
> +See linkgit:git-merge[1] for details, including how conflicts
> +are presented and handled.  To cancel a conflicting merge,
> +use `git reset --merge`.
> +
> +If any of the remote changes overlap with local uncommitted changes,
> +the merge will be automatically cancelled and the work tree untouched.
> +It is generally best to get any local changes in working order before
> +pulling or stash them away with linkgit:git-stash[1].

There's a slight risk with it because people might read this version
of the manpage online and then conclude that it is safe to try a merge
with uncommitted changes, only to find that their git-reset doesn't
support --merge yet.  Or worse, verify that their git-reset has
--merge by a quick test (1b5b465 is in 1.6.2) but then find that it
does not help with backing out of a merge (e11d7b5 is only in 1.7.0!).

Then again, who reads these manpages anyway?  And we shouldn't let old
versions get in the way of having consistent and up-to-date docs.  So,

Acked-by: Thomas Rast <trast@student.ethz.ch>

-- 
Thomas Rast
trast@{inf,student}.ethz.ch

  reply	other threads:[~2010-07-26  7:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-26  0:34 need advice on usage patterns Geoff Russell
2010-07-26  3:36 ` git pull (Re: need advice on usage patterns) Jonathan Nieder
2010-07-26  7:16   ` Thomas Rast [this message]
2010-07-26 20:06     ` Jonathan Nieder
2010-07-27  9:13       ` Thomas Rast
2010-07-26 10:26   ` Ævar Arnfjörð Bjarmason
2010-07-26 10:37     ` Geoff Russell
2010-07-26 14:17     ` Jonathan Nieder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201007260916.27306.trast@student.ethz.ch \
    --to=trast@student.ethz.ch \
    --cc=geoffrey.russell@gmail.com \
    --cc=git@drmicha.warpmail.net \
    --cc=git@vger.kernel.org \
    --cc=jrnieder@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).