dyre-0.9.1: Dynamic reconfiguration in Haskell
Safe HaskellNone
LanguageHaskell2010

Config.Dyre.Paths

Description

File paths of interest to Dyre, and related values.

Synopsis

Documentation

data PathsConfig Source #

Data type to make it harder to confuse which path is which.

Constructors

PathsConfig 

Fields

  • runningExecutable :: FilePath
     
  • customExecutable :: FilePath
     
  • configFile :: FilePath

    Where Dyre looks for the custom configuration file.

  • libsDirectory :: FilePath

    configDir/libs. This directory gets added to the GHC include path during compilation, so use configurations can be split up into modules. Changes to files under this directory trigger recompilation.

  • cacheDirectory :: FilePath

    Where the custom executable, object and interface files, errors file and other metadata get stored.

outputExecutable :: FilePath -> FilePath Source #

Determine a file name for the compiler to write to, based on the customExecutable path.

getPaths :: Params c r -> IO (FilePath, FilePath, FilePath, FilePath, FilePath) Source #

Return a PathsConfig, which records the current binary, the custom binary, the config file, and the cache directory.

maybeModTime :: FilePath -> IO (Maybe UTCTime) Source #

Check if a file exists. If it exists, return Just the modification time. If it doesn't exist, return Nothing.

findHaskellFiles :: FilePath -> IO [FilePath] Source #

Recursively find Haskell files (.hs, .lhs) at the given location.