summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--combox/file.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/combox/file.py b/combox/file.py
index 99050cf..a9f1208 100644
--- a/combox/file.py
+++ b/combox/file.py
@@ -136,6 +136,11 @@ def move_shards(src, dest, config):
config: a dictionary containing configuration info about combox.
"""
+ if path.basename(src) == path.basename(dest):
+ # this means the parent directory was rename, no the file
+ # itself! So we don't have to do anything.
+ return
+
nodes = get_nodedirs(config)
src_rel_path = relative_path(src, config)