avoid setting annex.direct in bare repo (no behavior change, just less ugly)
This commit is contained in:
parent
a64106dcef
commit
952537166e
1 changed files with 10 additions and 9 deletions
19
Init.hs
19
Init.hs
|
@ -160,15 +160,16 @@ checkCrippledFileSystem = whenM probeCrippledFileSystem $ do
|
|||
setConfig (ConfigKey "core.symlinks")
|
||||
(Git.Config.boolConfig False)
|
||||
|
||||
unlessM isDirect $ do
|
||||
warning "Enabling direct mode."
|
||||
top <- fromRepo Git.repoPath
|
||||
(l, clean) <- inRepo $ Git.LsFiles.inRepo [top]
|
||||
forM_ l $ \f ->
|
||||
maybe noop (`toDirect` f) =<< isAnnexLink f
|
||||
void $ liftIO clean
|
||||
setDirect True
|
||||
setVersion directModeVersion
|
||||
unlessBare $ do
|
||||
unlessM isDirect $ do
|
||||
warning "Enabling direct mode."
|
||||
top <- fromRepo Git.repoPath
|
||||
(l, clean) <- inRepo $ Git.LsFiles.inRepo [top]
|
||||
forM_ l $ \f ->
|
||||
maybe noop (`toDirect` f) =<< isAnnexLink f
|
||||
void $ liftIO clean
|
||||
setDirect True
|
||||
setVersion directModeVersion
|
||||
|
||||
probeFifoSupport :: Annex Bool
|
||||
probeFifoSupport = do
|
||||
|
|
Loading…
Add table
Reference in a new issue