aboutsummaryrefslogtreecommitdiff
path: root/Logs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2017-09-12 14:19:26 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2017-09-12 14:21:15 -0400
commitc2dd2a28a55709d598fef4e05ac7bfd6291479b5 (patch)
tree5e4b938be43b1df34de4a1399974d9fb10b9f3d7 /Logs
parentd9b80aca317a2484df5922d589b7b5e3bc30aa4a (diff)
leave export logged as incomplete if initial renames fail
This way, the temp files that might be left due to failure will be cleaned up next time. Also, nub the list of incomplete exports to avoid repeatedly adding the same tree to it when running export repeatedly when it's failing. This commit was supported by the NSF-funded DataLad project.
Diffstat (limited to 'Logs')
-rw-r--r--Logs/Export.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Logs/Export.hs b/Logs/Export.hs
index 3ba77cd24..2327d70d1 100644
--- a/Logs/Export.hs
+++ b/Logs/Export.hs
@@ -84,7 +84,7 @@ recordExportBeginning remoteuuid newtree = do
. M.lookup u . simpleMap
. parseLogNew parseExportLog
<$> Annex.Branch.get exportLog
- let new = old { incompleteExportedTreeish = newtree:incompleteExportedTreeish old }
+ let new = old { incompleteExportedTreeish = nub (newtree:incompleteExportedTreeish old) }
Annex.Branch.change exportLog $
showLogNew formatExportLog
. changeLog c u (ExportLog new remoteuuid)