git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Phillip Wood <phillip.wood@talktalk.net>
To: Junio C Hamano <gitster@pobox.com>
Cc: Philip Oakley <philipoakley@iee.org>,
	William Duclot <william.duclot@gmail.com>,
	git@vger.kernel.org
Subject: Re: [PATCH/RFC] rebase: make resolve message clearer for inexperienced users
Date: Wed, 26 Jul 2017 15:37:12 +0100	[thread overview]
Message-ID: <96c186b0-84ca-d97f-d745-099a730745c8@talktalk.net> (raw)
In-Reply-To: <xmqqmv7td0a5.fsf@gitster.mtv.corp.google.com>

On 24/07/17 21:53, Junio C Hamano wrote:
> Phillip Wood <phillip.wood@talktalk.net> writes:
> 
>> git rebase --continue requiring one to git add first confuses/annoys me
>> too. I started a patch to autostage unstaged changes if they don't
>> contain conflict markers a couple of weeks ago, I'll clean it up and
>> post it later this week.
> 
> As long as "git rebase" will keep refusing to start in a working
> tree with dirty files and/or index, this could be a good change.
> 
> But people _may_ be annoyed because they expect "--continue" to
> remind them that some conflicts are not concluded with an explicit
> "git add", and they would even feel that you made the command unsafe
> if "--continue" just goes ahead by auto-adding their change that is
> still work-in-progress.  Lack of conflict markers is not a sign that
> a file is fully resolved (which they are used to signal by "git
> add", and they do so per set of paths).

Thanks for your comments, I've tried to address them in the message with 
the patches I sent earlier today [1]. In summary autostaging is opt-in 
and the conflict marker check isn't perfect but it's better than nothing 
and covers an important case where the user has simply overlooked a 
conflict.

>> I also find it confusing that it asks me to edit the commit message for
>> picks, fixups and non-final squashes after conflicts. I can see that
>> perhaps one might want to amend the message to reflect any changes that
>> were made while resolving the conflicts but I've never had too. I'd
>> rather be able to pass --edit to rebase --continue if I needed to edit
>> the message in those cases. Looking through the code I think it would
>> require saving some extra state when rebase bails out on conflicts so
>> rebase --continue could tell if it should be asking the user to amend
>> the message.
> 
> This is disruptive if done without a careful transition plan and
> you'll annoy existing users who expect to be able to edit by
> default.  Especially since "rebase" keeps going and potentially
> rebuild many commits on top, by the time they realize the mistake of
> not passing "--edit", it is too late and they will hate you for
> forcing them rebase many commits again.

I agree, I was imagining the new behaviour would be opt in via a config 
variable. Then if in the future there is a consensus to enable the new 
behaviour by default there would be a transition phase where users of 
the old behaviour would get a message telling that the behaviour is 
going to change in the future and what value to set the config variable 
to in order to keep the old behaviour if that's what they want.

> If these suggestions above were given while "rebase -i" was
> developed, it might have made the end-user experience a better one
> than what it currently is, but transitioning after the current
> behaviour has long been established makes it much harder.

Sadly I didn't even know git existed at the time rebase was first added.

Best Wishes

Phillip


[1] 
https://public-inbox.org/git/20170726102720.15274-2-phillip.wood@talktalk.net/T/#u


      reply	other threads:[~2017-07-26 14:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-09 20:25 [PATCH/RFC] rebase: make resolve message clearer for inexperienced users William Duclot
2017-07-10 16:31 ` Junio C Hamano
2017-07-10 18:31   ` William Duclot
2017-07-12 21:29     ` Junio C Hamano
2017-07-16 11:39       ` Philip Oakley
2017-07-24  9:51         ` Phillip Wood
2017-07-24 20:53           ` Junio C Hamano
2017-07-26 14:37             ` Phillip Wood [this message]

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=96c186b0-84ca-d97f-d745-099a730745c8@talktalk.net \
    --to=phillip.wood@talktalk.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=philipoakley@iee.org \
    --cc=phillip.wood@dunelm.org.uk \
    --cc=william.duclot@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).