rename for clarity
Associated files are recorded now also for locked files, but this is only needed to populate unlocked files.
This commit is contained in:
parent
8f66f73fea
commit
673b2feaf3
1 changed files with 5 additions and 5 deletions
|
@ -179,7 +179,7 @@ ingest' preferredbackend meterupdate (Just (LockedDown cfg source)) mk restage =
|
||||||
golocked key mcache s =
|
golocked key mcache s =
|
||||||
tryNonAsync (moveAnnex key naf (contentLocation source)) >>= \case
|
tryNonAsync (moveAnnex key naf (contentLocation source)) >>= \case
|
||||||
Right True -> do
|
Right True -> do
|
||||||
populateAssociatedFiles key source restage
|
populateUnlockedFiles key source restage
|
||||||
success key mcache s
|
success key mcache s
|
||||||
Right False -> giveup "failed to add content to annex"
|
Right False -> giveup "failed to add content to annex"
|
||||||
Left e -> restoreFile (keyFilename source) key e
|
Left e -> restoreFile (keyFilename source) key e
|
||||||
|
@ -221,11 +221,11 @@ finishIngestUnlocked' :: Key -> KeySource -> Restage -> Annex ()
|
||||||
finishIngestUnlocked' key source restage = do
|
finishIngestUnlocked' key source restage = do
|
||||||
Database.Keys.addAssociatedFile key
|
Database.Keys.addAssociatedFile key
|
||||||
=<< inRepo (toTopFilePath (keyFilename source))
|
=<< inRepo (toTopFilePath (keyFilename source))
|
||||||
populateAssociatedFiles key source restage
|
populateUnlockedFiles key source restage
|
||||||
|
|
||||||
{- Copy to any other locations using the same key. -}
|
{- Copy to any unlocked files using the same key. -}
|
||||||
populateAssociatedFiles :: Key -> KeySource -> Restage -> Annex ()
|
populateUnlockedFiles :: Key -> KeySource -> Restage -> Annex ()
|
||||||
populateAssociatedFiles key source restage = do
|
populateUnlockedFiles key source restage = do
|
||||||
obj <- calcRepo (gitAnnexLocation key)
|
obj <- calcRepo (gitAnnexLocation key)
|
||||||
g <- Annex.gitRepo
|
g <- Annex.gitRepo
|
||||||
ingestedf <- flip fromTopFilePath g
|
ingestedf <- flip fromTopFilePath g
|
||||||
|
|
Loading…
Reference in a new issue