aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-08-24 12:05:44 -0700
committerJunio C Hamano <gitster@pobox.com>2012-08-24 12:05:44 -0700
commitbdb30339f6dd122f27d4a6ffaeaa45b1c7e736e3 (patch)
treed787bb811b463e00175223b4f04f4a7ccdd95c18
parent7939a33425d0efabb9d1ce3f94ecbc3ef560c359 (diff)
parent9c81990bdd9277dc791914c1db7dfadbe3592d3a (diff)
downloadgit-bdb30339f6dd122f27d4a6ffaeaa45b1c7e736e3.tar.gz
git-bdb30339f6dd122f27d4a6ffaeaa45b1c7e736e3.tar.xz
Merge branch 'jc/maint-abbrev-option-cli' into maint-1.7.11
We did not document that many commands take unique prefix abbreviations of long options (e.g. "--option" may be the only flag that the command accepts that begin with "--opt", in which case you can give "--opt") anywhere easy to find for new people. * jc/maint-abbrev-option-cli: gitcli: describe abbreviation of long options
-rw-r--r--Documentation/gitcli.txt8
1 files changed, 8 insertions, 0 deletions
diff --git a/Documentation/gitcli.txt b/Documentation/gitcli.txt
index ea17f7a53..3e72a5d68 100644
--- a/Documentation/gitcli.txt
+++ b/Documentation/gitcli.txt
@@ -62,6 +62,14 @@ scripting git:
`git log -1 HEAD` but write `git log -1 HEAD --`; the former will not work
if you happen to have a file called `HEAD` in the work tree.
+ * many commands allow a long option "--option" to be abbreviated
+ only to their unique prefix (e.g. if there is no other option
+ whose name begins with "opt", you may be able to spell "--opt" to
+ invoke the "--option" flag), but you should fully spell them out
+ when writing your scripts; later versions of Git may introduce a
+ new option whose name shares the same prefix, e.g. "--optimize",
+ to make a short prefix that used to be unique no longer unique.
+
ENHANCED OPTION PARSER
----------------------