@matheusbsbs / matheus-bagliano / commits / 92f65e6ab6
Fork 0

git am: Remove stray error message from sed

When --continue is invoked without any changes, the following stray error message appears- sed: can't read $dotest/final-commit: No such file or directory. Remove this by making sure that the file actually exists. Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Ramkumar Ramachandra committed Jun 2, 2010 at 10:33 UTC 92f65e6ab6185aae241d1388b54429d171a9d0f5
1 file changed +7 -1
git-am.sh
+7 -1
@@ -693,7 +693,13 @@ do
693 else
694 action=yes
695 fi
696 - FIRSTLINE=$(sed 1q "$dotest/final-commit")
696 +
697 + if test -f "$dotest/final-commit"
698 + then
699 + FIRSTLINE=$(sed 1q "$dotest/final-commit")
700 + else
701 + FIRSTLINE=""
702 + fi
703
704 if test $action = skip
705 then