Thread (12 messages) flat view 12 messages, 5 authors, 2016-06-15

Re: [PATCH v2] git-commit.txt: Correct option alternatives

From: Jeff King <hidden>
Date: 2016-06-15 22:44:42

On Sat, Jun 07, 2008 at 08:36:54PM -0500, Jon Loeliger wrote:
quoted
Furthermore, for long-option consistency --author <author>
is changed to --author=<author>.
Say, if we were to document and espouse one form over the other,
which would you recommend or prefer?
$ sed -ne '/sticked/,/^$/p' Documentation/gitcli.txt
 * when a command line option takes an argument, use the 'sticked' form.  In
   other words, write `"git foo -oArg"` instead of `"git foo -o Arg"` for short
   options, and `"git foo --long-opt=Arg"` instead of `"git foo --long-opt Arg"`
   for long options.  An option that takes optional option-argument must be
   written in the 'sticked' form.

'sticked' form must be used:
----------------------------
$ git describe --abbrev HEAD     # correct
$ git describe --abbrev=10 HEAD  # correct
$ git describe --abbrev 10 HEAD  # NOT WHAT YOU MEANT
----------------------------

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help