On Mon, May 31, 2010 at 16:49, Philip Jackson <[email protected]> wrote:
> I've just push rebase-mode (not requred in magit itself and not part
> of the deployment process). It's a mode for editing the
> git-rebase-todo file.
>
> Give it a try, if it's useless I'll get rid/improve it, otherwise
> perhaps magit could eventually load it.

This is definitely useful. Doing rebases is pretty much the last thing
that I do in a non-Emacs fashion with Git. I sent you a minor patch
for it.

Scary braindump follows:

I don't like there not being "p" and "n" keys to move
back/forward. But I could see how moving "p" away from "pick" would be
really confusing. Nevertheless I'm using this customization for
myself:

    (define-key rebase-mode-map (kbd "i") 'rebase-mode-pick)
    (define-key rebase-mode-map (kbd "p") 'previous-line)
    (define-key rebase-mode-map (kbd "n") 'next-line)

The highlighting colors in the mode appear seemingly at random. When I
start a new rebase for magit's master^^ I get highlighted entries on
the first line and later (seemingly at random) in the list. Moving
commits around at the top of the list moves the highlighting between
seemingly unrelated commits at the bottom.

When I mark some commits for "edit" magit will stop at a detached head
as expected. However after I've amended/stashed more stuff, how do I
continue the rebase? I.e. git commit --amend && git rebase --continue?

When I press "E" in a running rebase it offers to start a new rebase
and then says "rebase already running". Is there any reason not to
just switch to the git-rebase-todo buffer here?

When I'm in git-rebase-todo C-x C-f will bring up
$where_i_was/.git/rebase-merge/. Maybe change the cwd back to
$where_i_was?

It would also be nice if "Type C-c C-c to commit (C-c C-k to cancel)."
worked in the git-rebase-todo buffer.

I'm not sure how, but I managed to make it cry by somehow killing the
git-rebase-todo buffer so that Git didn't have a chance to clean up
after itself. When I started a new rebase after that I got:

    $ git --no-pager rebase -i master^
    Interactive rebase already started
    Git exited abnormally with code 1.

That needed a git rebase --abort in a shell to clean up.

Anyway; </scary braindump> the mode is awesome, thanks for hacking it.

Reply via email to