From: "Torsten Bögershausen" <tboegi@web.de>
To: Scott Schmit <i.grok@comcast.net>, Junio C Hamano <gitster@pobox.com>
Cc: "Torsten Bögershausen" <tboegi@web.de>,
git@vger.kernel.org, eda@waniasset.com,
"Duy Nguyen" <pclouds@gmail.com>
Subject: Re: [PATCH] git-checkout.txt: Document "git checkout <pathspec>" better
Date: Fri, 12 Jun 2015 22:41:26 +0200 [thread overview]
Message-ID: <557B43F6.9070502@web.de> (raw)
In-Reply-To: <20150612044906.GA17424@odin.ulthar.us>
On 2015-06-12 06.49, Scott Schmit wrote:
> 'git checkout' with <paths> or `--patch` is used to restore modified or
> deleted paths to their original contents from the index or replace paths
> with the contents from a named <tree-ish> (most often a commit-ish)
> instead of switching branches.
-------------------
I will probably send a patch, the next days or so.
It feels as if we can split the long sentence, and differntiate
between the "restore" and "copy content from other tree-sh".
How about this:
'git checkout' [--] <pathspec>...::
'git checkout' with <paths> is used to restore modified or
deleted paths to their original contents from the index.
'git checkout' [-p|--patch] [<tree-ish>] [--] <pathspec>...::
'git checkout' with [<tree-ish>] and <paths> or `--patch` is used
to replace <paths> with the contents from a named <tree-ish>
(most often a commit-ish) instead of switching branches.
In this case, the `-b` and `--track` options are
meaningless and giving either of them results in an error. The
<tree-ish> argument can be used to specify a specific tree-ish
(i.e. commit, tag or tree) to update the index for the given
paths before updating the working tree.
+
prev parent reply other threads:[~2015-06-12 20:41 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-08 20:21 [PATCH] git-checkout.txt: Document "git checkout <pathspec>" better Torsten Bögershausen
2015-06-10 15:05 ` Junio C Hamano
2015-06-10 15:11 ` Ed Avis
2015-06-10 16:38 ` Junio C Hamano
2015-06-11 10:24 ` [PATCH] git-checkout.txt: Document Ed Avis
2015-06-10 18:27 ` [PATCH] git-checkout.txt: Document "git checkout <pathspec>" better Torsten Bögershausen
2015-06-11 14:47 ` Junio C Hamano
2015-06-11 14:52 ` Ed Avis
2015-06-11 18:23 ` Junio C Hamano
2015-06-12 4:49 ` Scott Schmit
2015-06-12 16:24 ` Junio C Hamano
2015-06-12 20:41 ` Torsten Bögershausen [this message]
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=557B43F6.9070502@web.de \
--to=tboegi@web.de \
--cc=eda@waniasset.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=i.grok@comcast.net \
--cc=pclouds@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.