git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yann Dirson <ydirson@free.fr>
To: Christian Couder <chriscool@tuxfamily.org>
Cc: Martin von Zweigbergk <martin.von.zweigbergk@gmail.com>,
	git@vger.kernel.org, Johannes.Schindelin@gmx.de,
	christian.couder@gmail.com, trast@student.ethz.ch
Subject: Re: Refactoring git-rebase.sh and git-rebase--interactive.sh
Date: Thu, 4 Nov 2010 22:15:56 +0100	[thread overview]
Message-ID: <20101104211556.GB8911@home.lan> (raw)
In-Reply-To: <201011030424.33093.chriscool@tuxfamily.org>

Hi Christian,

On Wed, Nov 03, 2010 at 04:24:32AM +0100, Christian Couder wrote:
> Now that GTAC (http://www.gtac.biz) is over, I plan to work on options 
> --continue, --abort and --skip for git cherry-pick/revert. After that I hope 
> to be able to refactor the code so that in the end common code is used by 
> cherry-pick/revert and rebase.

Sounds like "sequencer is coming back", great news :)

I don't know if you would like the idea enough, but something I often
think would be good to have (and which could be useful for cherry-pick
and other commands in need of a sequencer), would be more flexibility.
The thing I find myself lacking most often, is the possibility to
change my mind on an already-edited commit (ie, go back after
--continue), the alternatives I can see today being:

- keeping a note on what to do on next pass (but may be more work in case
  of conflicts with further commits)
- fast-forward --continue'ing to keep curent changes and add new ones in
  next pass (same restriction)
- --abort'ing the rebase and starting it again, possibly fetching the
  changes from previous run via HEAD's reflog (not very handy either)
- checkout back to where you want to re-amend and cherry-pick those you
  already passed, essentially redoing an interactive rebase by hand

If we could go back to previous commit, while keeping changes done to
the current one (say, --previous), or reverting to the original one
(say, --revert).  In the same way, continuing until another
previously-unforeseen commit without the need to edit the todo file
would be nice to have (eg. --next).

While I'm at it, another somewhat loosely option I have thought of
would be to seed the todo file with "edit" commands instead of "pick",
to make it possible to validate a series of patches one by one before
sending.  That could be generalized for running a test script
automatically, that is inserting "x whatever" between all pick's - and
my 1st idea would boil down to inserting arg-less "edit" or "x false"
instead.  Maybe some --stepcmd=<command> flag ?

-- 
Yann

  parent reply	other threads:[~2010-11-04 21:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-02 12:33 Refactoring git-rebase.sh and git-rebase--interactive.sh Martin von Zweigbergk
2010-11-02 12:46 ` Johannes Sixt
2010-11-03  3:24 ` Christian Couder
2010-11-03 12:22   ` Martin von Zweigbergk
2010-11-04 21:15   ` Yann Dirson [this message]
2010-11-04 21:49     ` Pat Notz
2010-11-05  8:58     ` Christian Couder
2010-11-06  2:03 ` Martin von Zweigbergk
2010-11-07  1:57   ` Martin von Zweigbergk

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=20101104211556.GB8911@home.lan \
    --to=ydirson@free.fr \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=chriscool@tuxfamily.org \
    --cc=christian.couder@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=martin.von.zweigbergk@gmail.com \
    --cc=trast@student.ethz.ch \
    /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).