summaryrefslogtreecommitdiff
path: root/git-mergetool.sh
diff options
context:
space:
mode:
authorRogan Dawes <rogan@dawes.za.net>2008-01-07 09:37:38 +0200
committerJunio C Hamano <gitster@pobox.com>2008-01-07 21:00:54 -0800
commit2e8fd7819521b43e89f3baa9c6a95042ed7da4b4 (patch)
tree9d3a8234fd76a9738bef08fe09858d866c1aef8c /git-mergetool.sh
parent7ec43959f779fa75278c204a71acd4572acc9a1e (diff)
downloadgit-2e8fd7819521b43e89f3baa9c6a95042ed7da4b4.tar.gz
Allow git-mergetool to handle paths with a leading space
Signed-off-by: Rogan Dawes <rogan@dawes.za.net>
Diffstat (limited to 'git-mergetool.sh')
-rwxr-xr-xgit-mergetool.sh7
1 files changed, 5 insertions, 2 deletions
diff --git a/git-mergetool.sh b/git-mergetool.sh
index 2f31fa2417..cbbb707959 100755
--- a/git-mergetool.sh
+++ b/git-mergetool.sh
@@ -393,8 +393,11 @@ if test $# -eq 0 ; then
echo "No files need merging"
exit 0
fi
- echo Merging the files: $files
- git ls-files -u | sed -e 's/^[^ ]* //' | sort -u | while read i
+ echo Merging the files: "$files"
+ git ls-files -u |
+ sed -e 's/^[^ ]* //' |
+ sort -u |
+ while IFS= read i
do
printf "\n"
merge_file "$i" < /dev/tty > /dev/tty