[PATCH] Prevent t6000 series from dropping useless sed.script in t/
[gitweb.git] / git-merge-one-file-script
index 88ad3edd64acf92dd11d690c110d42bef23a6187..9802f67032bde6bbd9edacb89f3a4acdf876deb9 100755 (executable)
@@ -22,8 +22,11 @@ case "${1:-.}${2:-.}${3:-.}" in
 #
 "$1.." | "$1.$1" | "$1$1.")
        echo "Removing $4"
-       rm -f -- "$4" &&
-               exec git-update-cache --remove -- "$4"
+       if test -f "$4"
+       then
+               rm -f -- "$4"
+       fi &&
+       exec git-update-cache --remove -- "$4"
        ;;
 
 #