From: Torsten Bögershausen Date: Wed, 17 Jun 2015 07:54:51 +0000 (+0200) Subject: git-checkout.txt: document "git checkout " better X-Git-Tag: v2.5.0-rc2~20^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c4ac525c847fe7058a00bcc0e0f2cb436f5e7976;p=thirdparty%2Fgit.git git-checkout.txt: document "git checkout " better git checkout can be used to reset changes in the working tree. Signed-off-by: Torsten Bögershausen Signed-off-by: Junio C Hamano --- diff --git a/Documentation/git-checkout.txt b/Documentation/git-checkout.txt index d5041082e8..7540e026f5 100644 --- a/Documentation/git-checkout.txt +++ b/Documentation/git-checkout.txt @@ -3,7 +3,7 @@ git-checkout(1) NAME ---- -git-checkout - Checkout a branch or paths to the working tree +git-checkout - Switch branches or restore working tree files SYNOPSIS -------- @@ -89,6 +89,10 @@ Omitting detaches HEAD at the tip of the current branch. (i.e. commit, tag or tree) to update the index for the given paths before updating the working tree. + +'git checkout' with 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 (most often a commit-ish). ++ The index may contain unmerged entries because of a previous failed merge. By default, if you try to check out such an entry from the index, the checkout operation will fail and nothing will be checked out.