more RawFilePath conversion
Added a RawFilePath createDirectory and kept making stuff build. Up to 296/645 This commit was sponsored by Mark Reidenbach on Patreon.
This commit is contained in:
parent
b8bd2e45e3
commit
8d66f7ba0f
18 changed files with 95 additions and 76 deletions
|
@ -5,11 +5,13 @@
|
|||
- Licensed under the GNU AGPL version 3 or higher.
|
||||
-}
|
||||
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
{-# LANGUAGE CPP #-}
|
||||
|
||||
module Remote.Helper.Hooks (addHooks) where
|
||||
|
||||
import qualified Data.Map as M
|
||||
import qualified System.FilePath.ByteString as P
|
||||
|
||||
import Annex.Common
|
||||
import Types.Remote
|
||||
|
@ -46,7 +48,7 @@ addHooks' r starthook stophook = r'
|
|||
runHooks :: Remote -> Maybe String -> Maybe String -> Annex a -> Annex a
|
||||
runHooks r starthook stophook a = do
|
||||
dir <- fromRepo gitAnnexRemotesDir
|
||||
let lck = dir </> remoteid ++ ".lck"
|
||||
let lck = dir P.</> remoteid <> ".lck"
|
||||
whenM (notElem lck . M.keys <$> getLockCache) $ do
|
||||
createAnnexDirectory dir
|
||||
firstrun lck
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue