summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 397c766)
raw | patch | inline | side by side (parent: 397c766)
author | Junio C Hamano <junkio@cox.net> | |
Sun, 20 Nov 2005 03:50:44 +0000 (19:50 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Sun, 20 Nov 2005 03:57:54 +0000 (19:57 -0800) |
When the last file in a directory is removed as the result of a
merge, try to rmdir the now-empty directory.
Signed-off-by: Junio C Hamano <junkio@cox.net>
merge, try to rmdir the now-empty directory.
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-merge-recursive.py | patch | blob | history |
diff --git a/git-merge-recursive.py b/git-merge-recursive.py
index d7d36aa7d11299d3a1e91dce1bc9572ac56a7c08..37258ad77481fb0edaf2b084b7be173d8da8c586 100755 (executable)
--- a/git-merge-recursive.py
+++ b/git-merge-recursive.py
except OSError, e:
if e.errno != errno.ENOENT and e.errno != errno.EISDIR:
raise
+ try:
+ os.removedirs(os.path.dirname(path))
+ except:
+ pass
def uniquePath(path, branch):
def fileExists(path):