From: Jeff King <peff@peff.net>
To: Duy Nguyen <pclouds@gmail.com>
Cc: Jonathan Nieder <jrnieder@gmail.com>,
Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH/RFC] commit: add short option for --amend
Date: Fri, 17 Aug 2018 11:26:56 -0400 [thread overview]
Message-ID: <20180817152655.GA4816@sigill.intra.peff.net> (raw)
In-Reply-To: <CACsJy8Di4GQLqkBmcnrfmU9aS=wizxU36Ly0BRgDEDmFG=+2Fg@mail.gmail.com>
On Fri, Aug 17, 2018 at 04:33:30PM +0200, Duy Nguyen wrote:
> On Fri, Aug 17, 2018 at 8:47 AM Jonathan Nieder <jrnieder@gmail.com> wrote:
> >
> > Nguyễn Thái Ngọc Duy wrote:
> >
> > > --- a/builtin/commit.c
> > > +++ b/builtin/commit.c
> > > @@ -1489,7 +1489,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
> > > STATUS_FORMAT_LONG),
> > > OPT_BOOL('z', "null", &s.null_termination,
> > > N_("terminate entries with NUL")),
> > > - OPT_BOOL(0, "amend", &amend, N_("amend previous commit")),
> > > + OPT_BOOL('j', "amend", &amend, N_("amend previous commit")),
> > [...]
> > > Thoughts?
> >
> > I'm not a fan. I would have trouble remembering what the short option
> > name means, and it matches the common --jobs option for parallelism
> > that many commands use. "git commit --am" works today already and
> > doesn't run into those problems.
>
> The alternative is -A or -M which may be easier associated with
> --amend. That "--am" also would break the moment somebody adds
> --amsomething.
I think "-A" has been considered as possibility for matching "commit -a"
/ "add -A" in the past, but I had trouble finding past discussion
(searching for "A" in the mailing list is not very productive). It was
mentioned in 3ba1f11426 (git-add --all: add all files, 2008-07-19), but
that was quite a while ago.
Not necessarily a blocker, but something to consider.
Like Jonathan, I do find "-j" a little non-intuitive, but I agree that
most of the intuitive ones are taken. :)
-Peff
next prev parent reply other threads:[~2018-08-17 15:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-16 18:31 [PATCH/RFC] commit: add short option for --amend Nguyễn Thái Ngọc Duy
2018-08-16 18:39 ` Jeff King
2018-08-16 18:46 ` Duy Nguyen
2018-08-17 6:47 ` Jonathan Nieder
2018-08-17 14:33 ` Duy Nguyen
2018-08-17 15:26 ` Jeff King [this message]
2018-08-17 15:31 ` Duy Nguyen
2018-08-17 15:31 ` Junio C Hamano
2018-08-18 7:24 ` Simon Ruderich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180817152655.GA4816@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=jrnieder@gmail.com \
--cc=pclouds@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).