commit immediately when adding removable drive repo
I noticed that adding a removable drive repo, then trying to add the same drive again resulted in the question about whether repos should be combined. This was because the uuid.log was not updated. Which happened because the new uuid did not get committed on the removable drive. This fixes that.
This commit is contained in:
parent
7936cc646d
commit
f53526501d
1 changed files with 5 additions and 1 deletions
|
@ -398,8 +398,12 @@ initRepo False _ dir desc = inDir dir $ do
|
|||
|
||||
initRepo' :: Maybe String -> Annex ()
|
||||
initRepo' desc = do
|
||||
unlessM isInitialized $
|
||||
unlessM isInitialized $ do
|
||||
initialize desc
|
||||
{- Ensure branch gets committed right away so it is
|
||||
- available for merging when a removable drive repo is being
|
||||
- added. -}
|
||||
Annex.Branch.commit "update"
|
||||
|
||||
{- Checks if the user can write to a directory.
|
||||
-
|
||||
|
|
Loading…
Reference in a new issue