Re: [PATCH] Allow to specify the editor used for git rebase -i by config/environment var
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Oct 17, 2011, 21:36 UTC
- Message-ID
- <7v1uubl2qs.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <57346812.Rh0UlzroDp@soybean>
Peter Oberndorfer <kumbayo84@arcor.de> writes:
Show 11 quoted lines
> The search order for choosing the sequence editor is: > $GIT_SEQUENCE_EDITOR > git config sequence.editor > git var GIT_EDITOR (default editor for commit messages) > > With this change is it possible to have a separate > (possibly graphical) editor that helps the user > during a interactive rebase. > > Using $GIT_EDITOR or core.editor config var for this is not possible > since they is also used to start the commit message editor for reword action.
Thanks. I'll reword the proposed commit log message before queuing, because it won't make _any_ sense to talk about the search order before telling what these things that are searched would do, or why they are useful things to have.
"rebase -i": support special-purpose editor to edit insn sheet
The insn sheet used by "rebase -i" is designed to be easily editable by
any text editor, but an editor that is specifically meant for it (but
is otherwise unsuitable for editing regular text files) could be useful
by allowing drag & drop reordering in a GUI environment, for example. The GIT_SEQUENCE_EDITOR environment variable and/or the sequence.editor
configuration variable can be used to specify such an editor, while
allowing the usual editor to be used to edit commit log messages. As
usual, the environment variable takes precedence over the configuration
variable. It is envisioned that other "sequencer" based tools will use the same
mechanism. Signed-off-by: Peter Oberndorfer <kumbayo84@arcor.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>