@matheusbsbs / matheus-bagliano / commits / ce3ca27545
Fork 0

git-merge-one-file: do not worry about 'rmdir -p' not removing directory.

9ae2172aed289f2706a0e88288909fa47eddd7e7 used "rmdir -p" carelessly, causing the more important "git-update-index --remove" to be skipped. Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Dec 1, 2005 at 17:02 UTC ce3ca275452cf069eb6451d6f5b0f424a6f046aa
1 file changed +1 -1
git-merge-one-file.sh
+1 -1
@@ -26,7 +26,7 @@ case "${1:-.}${2:-.}${3:-.}" in
26 fi
27 if test -f "$4"; then
28 rm -f -- "$4" &&
29 - rmdir -p "$(expr "$4" : '\(.*\)/')" 2>/dev/null
29 + rmdir -p "$(expr "$4" : '\(.*\)/')" 2>/dev/null || :
30 fi &&
31 exec git-update-index --remove -- "$4"
32 ;;