Re: [RFC PATCH 0/5] Add option to autostage changes when continuing a rebase
- From
- Phillip Wood <phillip.wood@talktalk.net>
- Date
- Aug 22, 2017, 10:54 UTC
- Message-ID
- <d1eaed1c-5e62-0a93-f65d-06be43812617@talktalk.net>
- In-Reply-To
- <xmqqinhg5ysf.fsf@gitster.mtv.corp.google.com>
On 21/08/17 23:41, Junio C Hamano wrote:
Show 14 quoted lines
> Phillip Wood <phillip.wood@talktalk.net> writes: > >> ... I prefer >> having to pass --autostage with --continue so that it is a concious >> decision by the user to stage unstaged changes when they continue rather >> than rebase just doing it each time it continues. > > In other words, instead of > > git add -u && git rebase --continue > > you would want a quicker way to say > > git rebase --continue $something_here
Exactly
> If that is the case, that is understandable to me. Is the "-u" (I > think "git add -u" is short for "--update" but I didn't check) taken > as a valid option to "git rebase"? If not, that $something_here could > be "-u".
At the moment $something_else is -a/--autostage but -u/--update (I've checked the add man page and you're right) could be good as well.
rebase --continue -a
behaves like commit -a in that it commits all updated tracked files and does not take pathspecs, if we go for -u then there is a difference with 'git add -u' as that can take an optional pathspec.
Did you have any further thoughts on what checks if any this new option should make to avoid staging obviously unresolved files?
> Thanks for pinging the thread; otherwise I would have forgotten, > especially because not many other people were involved in the > discussion to begin with.
Yes it would be interesting to hear if this would be useful for others too.
Best Wishes
Phillip