Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data Apply (a :: ApplyStrategy) where
- ApplySafe :: FilePath -> GenericPackageDescription -> Endo GenericPackageDescription -> Apply 'ApplyStrategySafe
- ApplySmart :: FilePath -> [Section] -> Endo [Section] -> Apply 'ApplyStrategySmart
- data SomeApply = forall (a :: ApplyStrategy). SomeApply {
- unSomeApply :: Apply a
- runApply :: SomeApply -> Package -> Set DependencyName -> Maybe Compilable -> ShouldApply -> IO (Bool, SomeApply)
- writeApply :: SomeApply -> IO ()
Documentation
data Apply (a :: ApplyStrategy) where Source #
Continuation GADT for applying changes to a cabal file.
ApplySafe :: FilePath -> GenericPackageDescription -> Endo GenericPackageDescription -> Apply 'ApplyStrategySafe | |
ApplySmart :: FilePath -> [Section] -> Endo [Section] -> Apply 'ApplyStrategySmart |
Wrap Apply
in a data type so that it can be passed to functions without escaping the inner type.
forall (a :: ApplyStrategy). SomeApply | |
|
runApply :: SomeApply -> Package -> Set DependencyName -> Maybe Compilable -> ShouldApply -> IO (Bool, SomeApply) Source #
Iterate on a cabal file by pruning one target at a time. Return whether the command-line call to prune-juice
should fail.
writeApply :: SomeApply -> IO () Source #
Write the series of changes to the cabal file.