doc: checkout: synchronize <pathspec> description
`git add` shows an example of good writing, follow it. Signed-off-by: Alexandr Miloslavskiy <alexandr.miloslavskiy@syntevo.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
6fdc9ad259
commit
8ea1189eac
@ -12,13 +12,13 @@ SYNOPSIS
|
|||||||
'git checkout' [-q] [-f] [-m] --detach [<branch>]
|
'git checkout' [-q] [-f] [-m] --detach [<branch>]
|
||||||
'git checkout' [-q] [-f] [-m] [--detach] <commit>
|
'git checkout' [-q] [-f] [-m] [--detach] <commit>
|
||||||
'git checkout' [-q] [-f] [-m] [[-b|-B|--orphan] <new_branch>] [<start_point>]
|
'git checkout' [-q] [-f] [-m] [[-b|-B|--orphan] <new_branch>] [<start_point>]
|
||||||
'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <paths>...
|
'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <pathspec>...
|
||||||
'git checkout' (-p|--patch) [<tree-ish>] [--] [<paths>...]
|
'git checkout' (-p|--patch) [<tree-ish>] [--] [<pathspec>...]
|
||||||
|
|
||||||
DESCRIPTION
|
DESCRIPTION
|
||||||
-----------
|
-----------
|
||||||
Updates files in the working tree to match the version in the index
|
Updates files in the working tree to match the version in the index
|
||||||
or the specified tree. If no paths are given, 'git checkout' will
|
or the specified tree. If no pathspec was given, 'git checkout' will
|
||||||
also update `HEAD` to set the specified branch as the current
|
also update `HEAD` to set the specified branch as the current
|
||||||
branch.
|
branch.
|
||||||
|
|
||||||
@ -78,13 +78,13 @@ be used to detach `HEAD` at the tip of the branch (`git checkout
|
|||||||
+
|
+
|
||||||
Omitting `<branch>` detaches `HEAD` at the tip of the current branch.
|
Omitting `<branch>` detaches `HEAD` at the tip of the current branch.
|
||||||
|
|
||||||
'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <paths>...::
|
'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <pathspec>...::
|
||||||
|
|
||||||
Overwrite paths in the working tree by replacing with the
|
Overwrite the contents of the files that match the pathspec.
|
||||||
contents in the index or in the `<tree-ish>` (most often a
|
When the `<tree-ish>` (most often a commit) is not given,
|
||||||
commit). When a `<tree-ish>` is given, the paths that
|
overwrite working tree with the contents in the index.
|
||||||
match the `<pathspec>` are updated both in the index and in
|
When the `<tree-ish>` is given, overwrite both the index and
|
||||||
the working tree.
|
the working tree with the contents at the `<tree-ish>`.
|
||||||
+
|
+
|
||||||
The index may contain unmerged entries because of a previous failed merge.
|
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
|
By default, if you try to check out such an entry from the index, the
|
||||||
@ -336,7 +336,13 @@ leave out at most one of `A` and `B`, in which case it defaults to `HEAD`.
|
|||||||
Tree to checkout from (when paths are given). If not specified,
|
Tree to checkout from (when paths are given). If not specified,
|
||||||
the index will be used.
|
the index will be used.
|
||||||
|
|
||||||
|
\--::
|
||||||
|
Do not interpret any more arguments as options.
|
||||||
|
|
||||||
|
<pathspec>...::
|
||||||
|
Limits the paths affected by the operation.
|
||||||
|
+
|
||||||
|
For more details, see the 'pathspec' entry in linkgit:gitglossary[7].
|
||||||
|
|
||||||
DETACHED HEAD
|
DETACHED HEAD
|
||||||
-------------
|
-------------
|
||||||
|
Reference in New Issue
Block a user