git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Jeff King <peff@peff.net>
Cc: Robert Dailey <rcdailey.lists@gmail.com>, Git <git@vger.kernel.org>
Subject: Re: Feature request: Add --no-edit to git tag command
Date: Thu, 04 Apr 2019 18:13:16 +0900	[thread overview]
Message-ID: <xmqqo95mf80j.fsf@gitster-ct.c.googlers.com> (raw)
In-Reply-To: <20190404015744.GF4409@sigill.intra.peff.net> (Jeff King's message of "Wed, 3 Apr 2019 21:57:44 -0400")

Jeff King <peff@peff.net> writes:

> On Wed, Apr 03, 2019 at 09:38:02AM -0500, Robert Dailey wrote:
>
>> Similar to git commit, it would be nice to have a --no-edit option for
>> git tag. Use case is when I force-recreate a tag:
>> 
>> $ git tag -af 1.0 123abc
>> 
>> An editor will be prompted with the previous annotated tag message. I
>> would like to add --no-edit to instruct it to use any previously
>> provided message and without prompting the editor:
>> 
>> $ git tag --no-edit -af 1.0 123abc
>
> Yeah, that sounds like a good idea.

I am not so sure this is a good idea, especially if the plan is to
do this alone without necessary associated change to make things
consistent.

The part that bothers me most is use of "-f".  The mentalitly behind
"-f" is "I am creating a new and tag that is totally unrelated to
any existing tag, but since the command refuses to reuse the ref to
point at my new tag, I am giving an '-f' to force (1) unpointing the
existing unrelated tag and (2) pointing the enwly created tag with
that tagname".

The proposed change still uses "-f" but wants to somehow take the
tag message from the unrelated tag that happens to sit at the same
place as the new tag wants to go.  That breaks the mental model a
big way.

If this were a new option that is spelled "--amend", I won't
be complaining, though.

  parent reply	other threads:[~2019-04-04  9:13 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-03 14:38 Feature request: Add --no-edit to git tag command Robert Dailey
2019-04-04  1:57 ` Jeff King
2019-04-04  3:26   ` Taylor Blau
2019-04-04 12:06     ` Jeff King
2019-04-04 13:56       ` Robert Dailey
2019-04-04 13:57         ` Robert Dailey
2019-04-05 22:21         ` Jeff King
2019-04-11 18:20           ` Bárbara de Castro Fernandes
2019-04-11 18:29             ` Jeff King
2019-04-12  2:32               ` Junio C Hamano
2019-04-12  2:33                 ` Jeff King
2019-04-04  9:13   ` Junio C Hamano [this message]
2019-04-04 12:01     ` Jeff King

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqo95mf80j.fsf@gitster-ct.c.googlers.com \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    --cc=rcdailey.lists@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.
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 NNTP newsgroup(s).