Fix bug in git-annex copy --from --to
authorJoey Hess <joeyh@joeyh.name>
Fri, 17 Nov 2023 20:30:20 +0000 (16:30 -0400)
committerJoey Hess <joeyh@joeyh.name>
Fri, 17 Nov 2023 20:30:20 +0000 (16:30 -0400)
Caused it to skip files that were locally present.

Sponsored-by: Dartmouth College's DANDI project
CHANGELOG
Command/Copy.hs
doc/bugs/copy_--from_--to_does_not_copy_if_present_locally/comment_2_e857c1d89b350517fcb9829e52d6c6db._comment [new file with mode: 0644]

index 9761f776a14e96423ad134a7e06a27b56c8079d3..f5f13c3f8817c4d03f37379c8e2489584f90e8c3 100644 (file)
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -17,6 +17,8 @@ git-annex (10.20230927) UNRELEASED; urgency=medium
     display how the size of repositories changed over time.
   * log: Added options --interval, --bytes, --received, and --gnuplot
     to tune the output of the above added options.
+  * Fix bug in git-annex copy --from --to that skipped files that were
+    locally present.
 
  -- Joey Hess <id@joeyh.name>  Tue, 10 Oct 2023 13:17:31 -0400
 
index 0034bb26cba2e9ca5d2d7707259ab7d8ad2506d0..88d645a693284897a831f238a6e974f986fce4e6 100644 (file)
@@ -68,7 +68,7 @@ seek' o fto = startConcurrency (Command.Move.stages fto) $ do
                        FromOrToRemote (FromRemote _) -> Just False
                        FromOrToRemote (ToRemote _) -> Just True
                        ToHere -> Just False
-                       FromRemoteToRemote _ _ -> Just False
+                       FromRemoteToRemote _ _ -> Nothing
                , usesLocationLog = True
                }
        keyaction = Command.Move.startKey fto Command.Move.RemoveNever
diff --git a/doc/bugs/copy_--from_--to_does_not_copy_if_present_locally/comment_2_e857c1d89b350517fcb9829e52d6c6db._comment b/doc/bugs/copy_--from_--to_does_not_copy_if_present_locally/comment_2_e857c1d89b350517fcb9829e52d6c6db._comment
new file mode 100644 (file)
index 0000000..d9d1bc1
--- /dev/null
@@ -0,0 +1,9 @@
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 2"""
+ date="2023-11-17T20:27:37Z"
+ content="""
+> So the file content being present locally prevents it sending it to the remote!
+
+Fixed that.
+"""]]