summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 740a8fc)
raw | patch | inline | side by side (parent: 740a8fc)
author | Jay Soffian <jaysoffian@gmail.com> | |
Mon, 19 Sep 2011 23:40:52 +0000 (19:40 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 20 Sep 2011 00:41:49 +0000 (17:41 -0700) |
Mostly fixed already by 6b44577 (mergetool: check return value
from read, 2011-07-01). Catch two uses it missed.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
from read, 2011-07-01). Catch two uses it missed.
Signed-off-by: Jay Soffian <jaysoffian@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-mergetool--lib.sh | patch | blob | history | |
git-mergetool.sh | patch | blob | history |
diff --git a/git-mergetool--lib.sh b/git-mergetool--lib.sh
index 4db9212331259664732f031438b7b87b7a10244f..a79a2ecd49411f30517943108851243afa64de7b 100644 (file)
--- a/git-mergetool--lib.sh
+++ b/git-mergetool--lib.sh
while true; do
echo "$MERGED seems unchanged."
printf "Was the merge successful? [y/n] "
- read answer
+ read answer || return 1
case "$answer" in
y*|Y*) status=0; break ;;
n*|N*) status=1; break ;;
diff --git a/git-mergetool.sh b/git-mergetool.sh
index 3c157bcd26232c758572bf908add44216cb8e2e7..b6d463f0d057361ab5909209d24fc8fd383a3dbb 100755 (executable)
--- a/git-mergetool.sh
+++ b/git-mergetool.sh
resolve_symlink_merge () {
while true; do
printf "Use (l)ocal or (r)emote, or (a)bort? "
- read ans
+ read ans || return 1
case "$ans" in
[lL]*)
git checkout-index -f --stage=2 -- "$MERGED"