summaryrefslogtreecommitdiff
path: root/Documentation/git-refs.adoc
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/git-refs.adoc')
-rw-r--r--Documentation/git-refs.adoc7
1 files changed, 7 insertions, 0 deletions
diff --git a/Documentation/git-refs.adoc b/Documentation/git-refs.adoc
index d462953fb5..bfa9b3ea2d 100644
--- a/Documentation/git-refs.adoc
+++ b/Documentation/git-refs.adoc
@@ -18,6 +18,7 @@ git refs list [--count=<count>] [--shell|--perl|--python|--tcl]
[--contains[=<object>]] [--no-contains[=<object>]]
[(--exclude=<pattern>)...] [--start-after=<marker>]
[ --stdin | (<pattern>...)]
+git refs exists <ref>
DESCRIPTION
-----------
@@ -38,6 +39,12 @@ list::
formatting, and sorting. This subcommand is an alias for
linkgit:git-for-each-ref[1] and offers identical functionality.
+exists::
+ Check whether the given reference exists. Returns an exit code of 0 if
+ it does, 2 if it is missing, and 1 in case looking up the reference
+ failed with an error other than the reference being missing. This does
+ not verify whether the reference resolves to an actual object.
+
OPTIONS
-------