From: Junio C Hamano <gitster@pobox.com>
To: Michael J Gruber <git@drmicha.warpmail.net>
Cc: Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>,
git@vger.kernel.org,
Johannes Schindelin <johannes.schindelin@gmx.de>,
Michael Haggerty <mhagger@alum.mit.edu>,
Matthieu Moy <Matthieu.Moy@imag.fr>
Subject: Re: Bug with fixup and autosquash
Date: Thu, 09 Feb 2017 11:46:44 -0800 [thread overview]
Message-ID: <xmqqpoirp2or.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <07eb2367-9509-afb0-2494-f02a44304bc4@drmicha.warpmail.net> (Michael J. Gruber's message of "Thu, 9 Feb 2017 16:07:22 +0100")
Michael J Gruber <git@drmicha.warpmail.net> writes:
> Junio C Hamano venit, vidit, dixit 08.02.2017 23:55:
>
>> Let's hear from some of those (Cc'ed) who were involved in an
>> earlier --autosquash thread.
>>
>> https://public-inbox.org/git/cover.1259934977.git.mhagger@alum.mit.edu/
>>
>>
>> [Footnote]
>>
>> *1* "rebase -i --autosquash" does understand "fixup! yyyyyy", so if
>> you are willing to accept the consequence of not being able to
>> rebase twice, you could instead do
>>
>> $ git commit -m "fixup! yyyyyy"
>>
>> I would think.
>
> Doesn't this indicate that rebase is fine as is?
Not really, unless you ignore "if you are willing to accept" part,
which actually is a big downside. And --fixup-fixed will make it
worse, unfortunately.
> - teach "git commit --fixup=<rev>" to check for duplicates (same prefix,
> maybe only in "recent" history) and make it issue a warning, say:
This is a very good idea worth pursuing, and (I didn't think things
through, though) we may even be able to bound "recent" without
heuristics---scanning between <rev> and the tip for duplicates might
be sufficient.
> Additionally, we could teach commit --fixup-fixed to commit -m "fixup!
> <sha1> <prefix>" so that we have both uniqueness and verbosity in the
> rebase-i-editor. This would allow "rebase -i" to fall back to the old
> mode when "<sha1>" is not in the range it operates on.
This is also a possibility, but it needs cooperation between both
"commit" and "rebase -i".
I personally do not think rewriting "fixup! yyyyyy" on the title
during rebase is worth doing, but that is not because I have a
concrete reason against it but it just sounds like too much magic to
my gut feeling. Perhaps it can be done reliably with minimal change
to the code. I dunno.
Thanks.
next prev parent reply other threads:[~2017-02-09 19:47 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-08 10:10 Bug with fixup and autosquash Ashutosh Bapat
2017-02-08 22:55 ` Junio C Hamano
2017-02-09 4:06 ` Ashutosh Bapat
2017-02-09 15:07 ` Michael J Gruber
2017-02-09 19:46 ` Junio C Hamano [this message]
2017-02-09 20:55 ` Johannes Schindelin
2017-02-09 21:21 ` Junio C Hamano
2017-02-09 22:02 ` Johannes Schindelin
2017-02-09 22:16 ` Junio C Hamano
2017-02-10 15:57 ` Johannes Schindelin
2017-02-10 19:02 ` Philip Oakley
2017-04-25 11:30 ` Johannes Schindelin
2017-02-09 23:31 ` Philip Oakley
2017-02-10 14:02 ` Johannes Schindelin
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=xmqqpoirp2or.fsf@gitster.mtv.corp.google.com \
--to=gitster@pobox.com \
--cc=Matthieu.Moy@imag.fr \
--cc=ashutosh.bapat@enterprisedb.com \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
--cc=johannes.schindelin@gmx.de \
--cc=mhagger@alum.mit.edu \
/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).