From: Junio C Hamano Date: Wed, 16 Apr 2008 23:46:26 +0000 (-0700) Subject: git-am: minor cleanup X-Git-Tag: v1.5.5.1~4^2~1 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=11dc4e70c33c2fbbff19014035d3bf624da1902c;p=git.git git-am: minor cleanup This moves the assignment to FIRSTLINE down so that we do not have to have multiple copies. Suggested by Linus. Signed-off-by: Junio C Hamano --- diff --git a/git-am.sh b/git-am.sh index 0f05a2cfe..6be33d9dd 100755 --- a/git-am.sh +++ b/git-am.sh @@ -355,7 +355,6 @@ do ;; esac esac - FIRSTLINE=$(head -1 "$dotest/final-commit") resume= if test "$interactive" = t @@ -376,7 +375,6 @@ do [aA]*) action=yes interactive= ;; [nN]*) action=skip ;; [eE]*) git_editor "$dotest/final-commit" - FIRSTLINE=$(head -1 "$dotest/final-commit") action=again ;; [vV]*) action=again LESS=-S ${PAGER:-less} "$dotest/patch" ;; @@ -386,6 +384,7 @@ do else action=yes fi + FIRSTLINE=$(head -1 "$dotest/final-commit") if test $action = skip then