When adding files to an adjusted branch set up by --unlock-present, add them unlocked, not locked
Missed this when implementing it because of the default case catching the new constructor. So, removed that default case to make sure future types of adjusted branches don't make the same mistake. Complicated by git-annex addurl --fast which adds the file whose content is not present, so it needs to stay unlocked when on such a branch. This commit was sponsored by Brock Spratlen on Patreon.
This commit is contained in:
parent
db1e6c0625
commit
6f78497572
6 changed files with 28 additions and 9 deletions
|
@ -172,6 +172,7 @@ perform :: AddOptions -> RawFilePath -> AddUnlockedMatcher -> CommandPerform
|
|||
perform o file addunlockedmatcher = withOtherTmp $ \tmpdir -> do
|
||||
lockingfile <- not <$> addUnlocked addunlockedmatcher
|
||||
(MatchingFile (FileInfo (Just file) file Nothing))
|
||||
True
|
||||
let cfg = LockDownConfig
|
||||
{ lockingFile = lockingfile
|
||||
, hardlinkFileTmpDir = Just tmpdir
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue