Doc/check-ref-format: clarify information about @{-N} syntax
commitc6342e052535a5097a5bebe270e01b3cc9014bc3
authorKaartic Sivaraam <kaartic.sivaraam@gmail.com>
Sat, 16 Dec 2017 08:13:49 +0000 (16 13:43 +0530)
committerJunio C Hamano <gitster@pobox.com>
Tue, 19 Dec 2017 18:00:45 +0000 (19 10:00 -0800)
tree80fb4a8109864e0ae9afcad36e0a62f28bd6443d
parent52015aaf9d19c97b52c47c7046058e6d029ff856
Doc/check-ref-format: clarify information about @{-N} syntax

When the N-th previous thing checked out syntax (@{-N}) is used
with '--branch' option of check-ref-format the result may not be
the name of a branch that currently exists or ever existed. This
is because @{-N} is used to refer to the N-th last checked out
"thing", which might be a commit object name if the previous check
out was a detached HEAD state; or a branch name, otherwise. The
documentation thus does a wrong thing by promoting it as the
"previous branch syntax".

State that @{-N} is the syntax for specifying "N-th last thing
checked out" and also state that the result of using @{-N} might
also result in an commit object name.

Signed-off-by: Kaartic Sivaraam <kaartic.sivaraam@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/git-check-ref-format.txt