Re: [PATCH v2] git-checkout.txt: Document "git checkout <pathspec>" better
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- Jun 17, 2015, 11:54 UTC
- Message-ID
- <vpqoaketusa.fsf@anie.imag.fr>
- In-Reply-To
- <mlrmnt$te5$1@ger.gmane.org>
"Andres G. Aragoneses" <knocte@gmail.com> writes:
Show 17 quoted lines
> On 17/06/15 12:54, Matthieu Moy wrote: >> Duy Nguyen <pclouds@gmail.com> writes: >> >>> On Wed, Jun 17, 2015 at 2:54 PM, Torsten Bögershausen <tboegi@web.de> wrote: >>>> -git-checkout - Checkout a branch or paths to the working tree >>>> +git-checkout - Switch branches or restore changes >>> >>> I didn't follow closely the previous discussion. >> >> (Neither did I) >> >>> Forgive me if this is already discussed, but I would keep the "in the >>> working tree". "Restore changes" alone seems vague. >> >> "Restore previous version" would be better than "Restore changes" to me. > > "previous version" sounds ambiguous.
Yes, but "git checkout" can do many things. It can restore an old commited state, restore from the index, ... so we need to either be vague, or use a long enumeration.
> How about "discard local changes"?
To me this describes "git checkout HEAD", but neither "git checkout -- file" nor "git checkout HEAD^^^".
-- Matthieu Moy http://www-verimag.imag.fr/~moy/