Documentation: describe check-ref-format --branch
Unless one already knew, it was not obvious what sort of shorthand "git check-ref-format --branch" expands. Explain it. The --branch argument is not optional. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Jonathan Nieder committed
Oct 12, 2009 at 00:28 UTC
604e0cb5cbd2ea2e37273e13f99b6572cd82b4c1
1 file changed
+6
-3
Documentation/git-check-ref-format.txt
+6
-3
@@ -9,7 +9,7 @@ SYNOPSIS
9
--------
10
[verse]
11
'git check-ref-format' <refname>
12
-'git check-ref-format' [--branch] <branchname-shorthand>
12
+'git check-ref-format' --branch <branchname-shorthand>
13
14
DESCRIPTION
15
-----------
@@ -57,8 +57,11 @@ reference name expressions (see linkgit:git-rev-parse[1]):
57
58
. at-open-brace `@{` is used as a notation to access a reflog entry.
59
60
-With the `--branch` option, it expands a branch name shorthand and
61
-prints the name of the branch the shorthand refers to.
60
+With the `--branch` option, it expands the ``previous branch syntax''
61
+`@{-n}`. For example, `@{-1}` is a way to refer the last branch you
62
+were on. This option should be used by porcelains to accept this
63
+syntax anywhere a branch name is expected, so they can act as if you
64
+typed the branch name.
65
66
EXAMPLE
67
-------