fix build on windows
Annex.GitOverlay was using a module that needs posix to build.
This commit is contained in:
parent
98a8a6da81
commit
d3d187c869
3 changed files with 15 additions and 9 deletions
13
Config.hs
13
Config.hs
|
@ -6,12 +6,14 @@
|
|||
-}
|
||||
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
{-# LANGUAGE CPP #-}
|
||||
|
||||
module Config (
|
||||
module Config,
|
||||
annexConfig,
|
||||
remoteAnnexConfig,
|
||||
remoteConfig,
|
||||
pidLockFile,
|
||||
) where
|
||||
|
||||
import Annex.Common
|
||||
|
@ -23,6 +25,7 @@ import Config.Cost
|
|||
import Config.DynamicConfig
|
||||
import Types.Availability
|
||||
import Types.GitConfig
|
||||
import Annex.Locations
|
||||
import Git.Types
|
||||
|
||||
{- Looks up a setting in git config. This is not as efficient as using the
|
||||
|
@ -83,3 +86,13 @@ crippledFileSystem = annexCrippledFileSystem <$> Annex.getGitConfig
|
|||
setCrippledFileSystem :: Bool -> Annex ()
|
||||
setCrippledFileSystem b =
|
||||
setConfig (annexConfig "crippledfilesystem") (Git.Config.boolConfig b)
|
||||
|
||||
pidLockFile :: Annex (Maybe FilePath)
|
||||
#ifndef mingw32_HOST_OS
|
||||
pidLockFile = ifM (annexPidLock <$> Annex.getGitConfig)
|
||||
( Just <$> Annex.fromRepo gitAnnexPidLockFile
|
||||
, pure Nothing
|
||||
)
|
||||
#else
|
||||
pidLockFile = pure Nothing
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue