copy: avoid updating location log when no copy is performed
git annex copy --to remote often does not need to copy a file, but it was still updating the location log in this case.
This commit is contained in:
parent
72b14ec998
commit
40df26757a
2 changed files with 11 additions and 4 deletions
|
@ -92,15 +92,16 @@ toPerform dest move key file = moveLock move key $ do
|
|||
ok <- upload (Remote.uuid dest) key (Just file) noRetry $
|
||||
Remote.storeKey dest key (Just file)
|
||||
if ok
|
||||
then finish
|
||||
then finish True
|
||||
else do
|
||||
when fastcheck $
|
||||
warning "This could have failed because --fast is enabled."
|
||||
stop
|
||||
Right True -> finish
|
||||
Right True -> finish False
|
||||
where
|
||||
finish = do
|
||||
Remote.logStatus dest key InfoPresent
|
||||
finish remotechanged = do
|
||||
when remotechanged $
|
||||
Remote.logStatus dest key InfoPresent
|
||||
if move
|
||||
then do
|
||||
whenM (inAnnex key) $ removeAnnex key
|
||||
|
|
6
debian/changelog
vendored
6
debian/changelog
vendored
|
@ -1,3 +1,9 @@
|
|||
git-annex (3.20120925) UNRELEASED; urgency=low
|
||||
|
||||
* copy: Avoid updating the location log when no copy is performed.
|
||||
|
||||
-- Joey Hess <joeyh@debian.org> Mon, 24 Sep 2012 19:58:07 -0400
|
||||
|
||||
git-annex (3.20120924) unstable; urgency=low
|
||||
|
||||
* assistant: New command, a daemon which does everything watch does,
|
||||
|
|
Loading…
Reference in a new issue