This is the order documented in git-config(1), so we should stick to it. Signed-off-by: Thomas Rast <trast@xxxxxxxxxxxxxxx> --- It's actually only _almost_ the documented order: the manpage says that $GIT_EDITOR is used when it is set, presumably even when it is set but empty. I cannot see how that would be useful however. git-notes.sh | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/git-notes.sh b/git-notes.sh index 246df65..6859470 100755 --- a/git-notes.sh +++ b/git-notes.sh @@ -35,7 +35,8 @@ edit) git cat-file blob :$COMMIT >> "$MESSAGE" 2> /dev/null fi - ${VISUAL:-${EDITOR:-vi}} "$MESSAGE" + core_editor="$(git config core.editor)" + ${GIT_EDITOR:-${core_editor:-${VISUAL:-${EDITOR:-vi}}}} "$MESSAGE" grep -v ^# < "$MESSAGE" | git stripspace > "$MESSAGE".processed mv "$MESSAGE".processed "$MESSAGE" -- 1.6.2.rc0.288.g6852b -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html