Hpack.Config

hpack-0.38.0: A modern format for Haskell packages

Safe Haskell | None
Language | Haskell2010

Hpack.Config

Synopsis

- data DecodeOptions = DecodeOptions {
  - decodeOptionsProgramName :: ProgramName
  - decodeOptionsTarget :: FilePath
  - decodeOptionsUserDataDir :: Maybe FilePath
  - decodeOptionsDecode :: FilePath -> IO (Either String ([String], Value))
  - decodeOptionsFormatYamlParseError :: FilePath -> ParseException -> String
  }
- newtype ProgramName = ProgramName {
  - unProgramName :: String
  }
- defaultDecodeOptions :: DecodeOptions
- packageConfig :: FilePath
- data DecodeResult = DecodeResult {
  - decodeResultPackage :: Package
  - decodeResultCabalVersion :: String
  - decodeResultCabalFile :: FilePath
  - decodeResultWarnings :: [String]
  }
- readPackageConfig :: DecodeOptions -> IO (Either String DecodeResult)
- readPackageConfigWithError :: DecodeOptions -> IO (Either HpackError DecodeResult)
- renamePackage :: String -> Package -> Package
- packageDependencies :: Package -> [(String, DependencyInfo)]
- package :: String -> String -> Package
- section :: a -> Section a
- data Package = Package {
  - packageCabalVersion :: CabalVersion
  - packageName :: String
  - packageVersion :: String
  - packageSynopsis :: Maybe String
  - packageDescription :: Maybe String
  - packageHomepage :: Maybe String
  - packageBugReports :: Maybe String
  - packageCategory :: Maybe String
  - packageStability :: Maybe String
  - packageAuthor :: [String]
  - packageMaintainer :: [String]
  - packageCopyright :: [String]
  - packageBuildType :: BuildType
  - packageLicense :: Maybe String
  - packageLicenseFile :: [FilePath]
  - packageTestedWith :: [String]
  - packageFlags :: [Flag]
  - packageExtraSourceFiles :: [Path]
  - packageExtraDocFiles :: [Path]
  - packageDataFiles :: [Path]
  - packageDataDir :: Maybe FilePath
  - packageSourceRepository :: Maybe SourceRepository
  - packageCustomSetup :: Maybe CustomSetup
  - packageLibrary :: Maybe (Section Library)
  - packageInternalLibraries :: Map String (Section Library)
  - packageExecutables :: Map String (Section Executable)
  - packageTests :: Map String (Section Executable)
  - packageBenchmarks :: Map String (Section Executable)
  - packageVerbatim :: [Verbatim]
  }
- data CabalVersion
  - = CabalVersion Version
  - | VerbatimCabalVersion String
- makeCabalVersion :: [Int] -> CabalVersion
- newtype Dependencies = Dependencies {
  - unDependencies :: Map String DependencyInfo
  }
- data DependencyInfo = DependencyInfo {
  - dependencyInfoMixins :: [String]
  - dependencyInfoVersion :: DependencyVersion
  }
- data VersionConstraint
  - = AnyVersion
  - | VersionRange String
- data DependencyVersion = DependencyVersion (Maybe SourceDependency) VersionConstraint
- data SourceDependency
  - = GitRef GitUrl GitRef (Maybe FilePath)
  - | Local FilePath
- type GitRef = String
- type GitUrl = String
- data BuildTool
  - = BuildTool String String
  - | LocalBuildTool String
- newtype SystemBuildTools = SystemBuildTools {
  - unSystemBuildTools :: Map String VersionConstraint
  }
- type GhcOption = String
- data Verbatim
  - = VerbatimLiteral String
  - | VerbatimObject (Map String VerbatimValue)
- data VerbatimValue
  - = VerbatimString String
  - | VerbatimNumber Scientific
  - | VerbatimBool Bool
  - | VerbatimNull
- verbatimValueToString :: VerbatimValue -> String
- data CustomSetup = CustomSetup {
  - customSetupDependencies :: Dependencies
  }
- data Section a = Section {
  - sectionData :: a
  - sectionSourceDirs :: [FilePath]
  - sectionDependencies :: Dependencies
  - sectionPkgConfigDependencies :: [String]
  - sectionDefaultExtensions :: [String]
  - sectionOtherExtensions :: [String]
  - sectionLanguage :: Maybe Language
  - sectionGhcOptions :: [GhcOption]
  - sectionGhcProfOptions :: [GhcProfOption]
  - sectionGhcSharedOptions :: [GhcOption]
  - sectionGhcjsOptions :: [GhcjsOption]
  - sectionCppOptions :: [CppOption]
  - sectionAsmOptions :: [AsmOption]
  - sectionAsmSources :: [Path]
  - sectionCcOptions :: [CcOption]
  - sectionCSources :: [Path]
  - sectionCxxOptions :: [CxxOption]
  - sectionCxxSources :: [Path]
  - sectionJsSources :: [Path]
  - sectionExtraLibDirs :: [FilePath]
  - sectionExtraLibraries :: [FilePath]
  - sectionExtraFrameworksDirs :: [FilePath]
  - sectionFrameworks :: [FilePath]
  - sectionIncludeDirs :: [FilePath]
  - sectionInstallIncludes :: [FilePath]
  - sectionLdOptions :: [LdOption]
  - sectionBuildable :: Maybe Bool
  - sectionConditionals :: [Conditional (Section a)]
  - sectionBuildTools :: Map BuildTool DependencyVersion
  - sectionSystemBuildTools :: SystemBuildTools
  - sectionVerbatim :: [Verbatim]
  }
- data Library = Library {
  - libraryExposed :: Maybe Bool
  - libraryVisibility :: Maybe String
  - libraryExposedModules :: [Module]
  - libraryOtherModules :: [Module]
  - libraryGeneratedModules :: [Module]
  - libraryReexportedModules :: [String]
  - librarySignatures :: [String]
  }
- data Executable = Executable {
  - executableMain :: Maybe FilePath
  - executableOtherModules :: [Module]
  - executableGeneratedModules :: [Module]
  }
- data Conditional a = Conditional {
  - conditionalCondition :: Cond
  - conditionalThen :: a
  - conditionalElse :: Maybe a
  }
- data Cond
  - = CondBool Bool
  - | CondExpression String
- data Flag = Flag {
  - flagName :: String
  - flagDescription :: Maybe String
  - flagManual :: Bool
  - flagDefault :: Bool
  }
- data SourceRepository = SourceRepository {
  - sourceRepositoryUrl :: String
  - sourceRepositorySubdir :: Maybe String
  }
- newtype Language = Language String
- data BuildType
  - = Simple
  - | Configure
  - | Make
  - | Custom
- type GhcProfOption = String
- type GhcjsOption = String
- type CppOption = String
- type AsmOption = String
- type CcOption = String
- type LdOption = String
- newtype Path = Path {
  - unPath :: FilePath
  }
- newtype Module = Module {
  - unModule :: String
  }

# Documentation

NOTE: This module is exposed to allow integration of Hpack into other tools. It is not meant for general use by end users. The following caveats apply:

- The API is undocumented, consult the source instead.
- The exposed types and functions primarily serve Hpack's own needs, not that of a public API. Breaking changes can happen as Hpack evolves.

As an Hpack user you either want to use the `hpack` executable or a build tool that supports Hpack (e.g. `stack` or `cabal2nix`).

data DecodeOptions #

Constructors

DecodeOptions |
Fields decodeOptionsProgramName :: ProgramName decodeOptionsTarget :: FilePath decodeOptionsUserDataDir :: Maybe FilePath decodeOptionsDecode :: FilePath -> IO (Either String ([String], Value)) decodeOptionsFormatYamlParseError :: FilePath -> ParseException -> String

newtype ProgramName #

Constructors

ProgramName |
Fields unProgramName :: String

#### Instances

Instances details

IsString ProgramName # |
Instance details Defined in Hpack.Error Methods fromString :: String -> ProgramName #
Show ProgramName # |
Instance details Defined in Hpack.Error Methods showsPrec :: Int -> ProgramName -> ShowS # show :: ProgramName -> String # showList :: [ProgramName] -> ShowS #
Eq ProgramName # |
Instance details Defined in Hpack.Error Methods (==) :: ProgramName -> ProgramName -> Bool # (/=) :: ProgramName -> ProgramName -> Bool #

defaultDecodeOptions :: DecodeOptions #

packageConfig :: FilePath #

data DecodeResult #

Constructors

DecodeResult |
Fields decodeResultPackage :: Package decodeResultCabalVersion :: String decodeResultCabalFile :: FilePath decodeResultWarnings :: [String]

#### Instances

Instances details

Show DecodeResult # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> DecodeResult -> ShowS # show :: DecodeResult -> String # showList :: [DecodeResult] -> ShowS #
Eq DecodeResult # |
Instance details Defined in Hpack.Config Methods (==) :: DecodeResult -> DecodeResult -> Bool # (/=) :: DecodeResult -> DecodeResult -> Bool #

readPackageConfig :: DecodeOptions -> IO (Either String DecodeResult) #

readPackageConfigWithError :: DecodeOptions -> IO (Either HpackError DecodeResult) #

renamePackage :: String -> Package -> Package #

packageDependencies :: Package -> [(String, DependencyInfo)] #

package :: String -> String -> Package #

section :: a -> Section a #

data Package #

Constructors

Package |
Fields packageCabalVersion :: CabalVersion packageName :: String packageVersion :: String packageSynopsis :: Maybe String packageDescription :: Maybe String packageHomepage :: Maybe String packageBugReports :: Maybe String packageCategory :: Maybe String packageStability :: Maybe String packageAuthor :: [String] packageMaintainer :: [String] packageCopyright :: [String] packageBuildType :: BuildType packageLicense :: Maybe String packageLicenseFile :: [FilePath] packageTestedWith :: [String] packageFlags :: [Flag] packageExtraSourceFiles :: [Path] packageExtraDocFiles :: [Path] packageDataFiles :: [Path] packageDataDir :: Maybe FilePath packageSourceRepository :: Maybe SourceRepository packageCustomSetup :: Maybe CustomSetup packageLibrary :: Maybe (Section Library) packageInternalLibraries :: Map String (Section Library) packageExecutables :: Map String (Section Executable) packageTests :: Map String (Section Executable) packageBenchmarks :: Map String (Section Executable) packageVerbatim :: [Verbatim]

#### Instances

Instances details

Show Package # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Package -> ShowS # show :: Package -> String # showList :: [Package] -> ShowS #
Eq Package # |
Instance details Defined in Hpack.Config Methods (==) :: Package -> Package -> Bool # (/=) :: Package -> Package -> Bool #

data CabalVersion #

Constructors

CabalVersion Version |
VerbatimCabalVersion String |

#### Instances

Instances details

Show CabalVersion # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> CabalVersion -> ShowS # show :: CabalVersion -> String # showList :: [CabalVersion] -> ShowS #
Eq CabalVersion # |
Instance details Defined in Hpack.Config Methods (==) :: CabalVersion -> CabalVersion -> Bool # (/=) :: CabalVersion -> CabalVersion -> Bool #
Ord CabalVersion # |
Instance details Defined in Hpack.Config Methods compare :: CabalVersion -> CabalVersion -> Ordering # (<) :: CabalVersion -> CabalVersion -> Bool # (<=) :: CabalVersion -> CabalVersion -> Bool # (>) :: CabalVersion -> CabalVersion -> Bool # (>=) :: CabalVersion -> CabalVersion -> Bool # max :: CabalVersion -> CabalVersion -> CabalVersion # min :: CabalVersion -> CabalVersion -> CabalVersion #

makeCabalVersion :: [Int] -> CabalVersion #

newtype Dependencies #

Constructors

Dependencies |
Fields unDependencies :: Map String DependencyInfo

#### Instances

Instances details

Monoid Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Methods mempty :: Dependencies # mappend :: Dependencies -> Dependencies -> Dependencies # mconcat :: [Dependencies] -> Dependencies #
Semigroup Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Methods (<>) :: Dependencies -> Dependencies -> Dependencies # sconcat :: NonEmpty Dependencies -> Dependencies # stimes :: Integral b => b -> Dependencies -> Dependencies #
IsList Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Associated Types
type Item Dependencies |
Instance details Defined in Hpack.Syntax.Dependencies type Item Dependencies = (String, DependencyInfo)
Methods fromList :: [Item Dependencies] -> Dependencies # fromListN :: Int -> [Item Dependencies] -> Dependencies # toList :: Dependencies -> [Item Dependencies] #
Show Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Methods showsPrec :: Int -> Dependencies -> ShowS # show :: Dependencies -> String # showList :: [Dependencies] -> ShowS #
Eq Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Methods (==) :: Dependencies -> Dependencies -> Bool # (/=) :: Dependencies -> Dependencies -> Bool #
FromValue Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies Methods fromValue :: Value -> Parser Dependencies #
type Item Dependencies # |
Instance details Defined in Hpack.Syntax.Dependencies type Item Dependencies = (String, DependencyInfo)

data DependencyInfo #

Constructors

DependencyInfo |
Fields dependencyInfoMixins :: [String] dependencyInfoVersion :: DependencyVersion

#### Instances

Instances details

Show DependencyInfo # |
Instance details Defined in Hpack.Syntax.Dependencies Methods showsPrec :: Int -> DependencyInfo -> ShowS # show :: DependencyInfo -> String # showList :: [DependencyInfo] -> ShowS #
Eq DependencyInfo # |
Instance details Defined in Hpack.Syntax.Dependencies Methods (==) :: DependencyInfo -> DependencyInfo -> Bool # (/=) :: DependencyInfo -> DependencyInfo -> Bool #
Ord DependencyInfo # |
Instance details Defined in Hpack.Syntax.Dependencies Methods compare :: DependencyInfo -> DependencyInfo -> Ordering # (<) :: DependencyInfo -> DependencyInfo -> Bool # (<=) :: DependencyInfo -> DependencyInfo -> Bool # (>) :: DependencyInfo -> DependencyInfo -> Bool # (>=) :: DependencyInfo -> DependencyInfo -> Bool # max :: DependencyInfo -> DependencyInfo -> DependencyInfo # min :: DependencyInfo -> DependencyInfo -> DependencyInfo #

data VersionConstraint #

Constructors

AnyVersion |
VersionRange String |

#### Instances

Instances details

Show VersionConstraint # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods showsPrec :: Int -> VersionConstraint -> ShowS # show :: VersionConstraint -> String # showList :: [VersionConstraint] -> ShowS #
Eq VersionConstraint # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods (==) :: VersionConstraint -> VersionConstraint -> Bool # (/=) :: VersionConstraint -> VersionConstraint -> Bool #
Ord VersionConstraint # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods compare :: VersionConstraint -> VersionConstraint -> Ordering # (<) :: VersionConstraint -> VersionConstraint -> Bool # (<=) :: VersionConstraint -> VersionConstraint -> Bool # (>) :: VersionConstraint -> VersionConstraint -> Bool # (>=) :: VersionConstraint -> VersionConstraint -> Bool # max :: VersionConstraint -> VersionConstraint -> VersionConstraint # min :: VersionConstraint -> VersionConstraint -> VersionConstraint #
FromValue VersionConstraint # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods fromValue :: Value -> Parser VersionConstraint #

data DependencyVersion #

Constructors

DependencyVersion (Maybe SourceDependency) VersionConstraint |

#### Instances

Instances details

Show DependencyVersion # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods showsPrec :: Int -> DependencyVersion -> ShowS # show :: DependencyVersion -> String # showList :: [DependencyVersion] -> ShowS #
Eq DependencyVersion # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods (==) :: DependencyVersion -> DependencyVersion -> Bool # (/=) :: DependencyVersion -> DependencyVersion -> Bool #
Ord DependencyVersion # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods compare :: DependencyVersion -> DependencyVersion -> Ordering # (<) :: DependencyVersion -> DependencyVersion -> Bool # (<=) :: DependencyVersion -> DependencyVersion -> Bool # (>) :: DependencyVersion -> DependencyVersion -> Bool # (>=) :: DependencyVersion -> DependencyVersion -> Bool # max :: DependencyVersion -> DependencyVersion -> DependencyVersion # min :: DependencyVersion -> DependencyVersion -> DependencyVersion #

data SourceDependency #

Constructors

GitRef GitUrl GitRef (Maybe FilePath) |
Local FilePath |

#### Instances

Instances details

Show SourceDependency # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods showsPrec :: Int -> SourceDependency -> ShowS # show :: SourceDependency -> String # showList :: [SourceDependency] -> ShowS #
Eq SourceDependency # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods (==) :: SourceDependency -> SourceDependency -> Bool # (/=) :: SourceDependency -> SourceDependency -> Bool #
Ord SourceDependency # |
Instance details Defined in Hpack.Syntax.DependencyVersion Methods compare :: SourceDependency -> SourceDependency -> Ordering # (<) :: SourceDependency -> SourceDependency -> Bool # (<=) :: SourceDependency -> SourceDependency -> Bool # (>) :: SourceDependency -> SourceDependency -> Bool # (>=) :: SourceDependency -> SourceDependency -> Bool # max :: SourceDependency -> SourceDependency -> SourceDependency # min :: SourceDependency -> SourceDependency -> SourceDependency #

type GitRef = String #

type GitUrl = String #

data BuildTool #

Constructors

BuildTool String String |
LocalBuildTool String |

#### Instances

Instances details

Show BuildTool # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> BuildTool -> ShowS # show :: BuildTool -> String # showList :: [BuildTool] -> ShowS #
Eq BuildTool # |
Instance details Defined in Hpack.Config Methods (==) :: BuildTool -> BuildTool -> Bool # (/=) :: BuildTool -> BuildTool -> Bool #
Ord BuildTool # |
Instance details Defined in Hpack.Config Methods compare :: BuildTool -> BuildTool -> Ordering # (<) :: BuildTool -> BuildTool -> Bool # (<=) :: BuildTool -> BuildTool -> Bool # (>) :: BuildTool -> BuildTool -> Bool # (>=) :: BuildTool -> BuildTool -> Bool # max :: BuildTool -> BuildTool -> BuildTool # min :: BuildTool -> BuildTool -> BuildTool #

newtype SystemBuildTools #

Constructors

SystemBuildTools |
Fields unSystemBuildTools :: Map String VersionConstraint

#### Instances

Instances details

Monoid SystemBuildTools # |
Instance details Defined in Hpack.Syntax.BuildTools Methods mempty :: SystemBuildTools # mappend :: SystemBuildTools -> SystemBuildTools -> SystemBuildTools # mconcat :: [SystemBuildTools] -> SystemBuildTools #
Semigroup SystemBuildTools # |
Instance details Defined in Hpack.Syntax.BuildTools Methods (<>) :: SystemBuildTools -> SystemBuildTools -> SystemBuildTools # sconcat :: NonEmpty SystemBuildTools -> SystemBuildTools # stimes :: Integral b => b -> SystemBuildTools -> SystemBuildTools #
Show SystemBuildTools # |
Instance details Defined in Hpack.Syntax.BuildTools Methods showsPrec :: Int -> SystemBuildTools -> ShowS # show :: SystemBuildTools -> String # showList :: [SystemBuildTools] -> ShowS #
Eq SystemBuildTools # |
Instance details Defined in Hpack.Syntax.BuildTools Methods (==) :: SystemBuildTools -> SystemBuildTools -> Bool # (/=) :: SystemBuildTools -> SystemBuildTools -> Bool #
FromValue SystemBuildTools # |
Instance details Defined in Hpack.Syntax.BuildTools Methods fromValue :: Value -> Parser SystemBuildTools #

type GhcOption = String #

data Verbatim #

Constructors

VerbatimLiteral String |
VerbatimObject (Map String VerbatimValue) |

#### Instances

Instances details

Show Verbatim # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Verbatim -> ShowS # show :: Verbatim -> String # showList :: [Verbatim] -> ShowS #
Eq Verbatim # |
Instance details Defined in Hpack.Config Methods (==) :: Verbatim -> Verbatim -> Bool # (/=) :: Verbatim -> Verbatim -> Bool #
FromValue Verbatim # |
Instance details Defined in Hpack.Config Methods fromValue :: Value -> Parser Verbatim #

data VerbatimValue #

Constructors

VerbatimString String |
VerbatimNumber Scientific |
VerbatimBool Bool |
VerbatimNull |

#### Instances

Instances details

Show VerbatimValue # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> VerbatimValue -> ShowS # show :: VerbatimValue -> String # showList :: [VerbatimValue] -> ShowS #
Eq VerbatimValue # |
Instance details Defined in Hpack.Config Methods (==) :: VerbatimValue -> VerbatimValue -> Bool # (/=) :: VerbatimValue -> VerbatimValue -> Bool #
FromValue VerbatimValue # |
Instance details Defined in Hpack.Config Methods fromValue :: Value -> Parser VerbatimValue #

verbatimValueToString :: VerbatimValue -> String #

data CustomSetup #

Constructors

CustomSetup |
Fields customSetupDependencies :: Dependencies

#### Instances

Instances details

Show CustomSetup # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> CustomSetup -> ShowS # show :: CustomSetup -> String # showList :: [CustomSetup] -> ShowS #
Eq CustomSetup # |
Instance details Defined in Hpack.Config Methods (==) :: CustomSetup -> CustomSetup -> Bool # (/=) :: CustomSetup -> CustomSetup -> Bool #

data Section a #

Constructors

Section |
Fields sectionData :: a sectionSourceDirs :: [FilePath] sectionDependencies :: Dependencies sectionPkgConfigDependencies :: [String] sectionDefaultExtensions :: [String] sectionOtherExtensions :: [String] sectionLanguage :: Maybe Language sectionGhcOptions :: [GhcOption] sectionGhcProfOptions :: [GhcProfOption] sectionGhcSharedOptions :: [GhcOption] sectionGhcjsOptions :: [GhcjsOption] sectionCppOptions :: [CppOption] sectionAsmOptions :: [AsmOption] sectionAsmSources :: [Path] sectionCcOptions :: [CcOption] sectionCSources :: [Path] sectionCxxOptions :: [CxxOption] sectionCxxSources :: [Path] sectionJsSources :: [Path] sectionExtraLibDirs :: [FilePath] sectionExtraLibraries :: [FilePath] sectionExtraFrameworksDirs :: [FilePath] sectionFrameworks :: [FilePath] sectionIncludeDirs :: [FilePath] sectionInstallIncludes :: [FilePath] sectionLdOptions :: [LdOption] sectionBuildable :: Maybe Bool sectionConditionals :: [Conditional (Section a)] sectionBuildTools :: Map BuildTool DependencyVersion sectionSystemBuildTools :: SystemBuildTools sectionVerbatim :: [Verbatim]

#### Instances

Instances details

Functor Section # |
Instance details Defined in Hpack.Config Methods fmap :: (a -> b) -> Section a -> Section b # (<$) :: a -> Section b -> Section a #
Foldable Section # |
Instance details Defined in Hpack.Config Methods fold :: Monoid m => Section m -> m # foldMap :: Monoid m => (a -> m) -> Section a -> m # foldMap' :: Monoid m => (a -> m) -> Section a -> m # foldr :: (a -> b -> b) -> b -> Section a -> b # foldr' :: (a -> b -> b) -> b -> Section a -> b # foldl :: (b -> a -> b) -> b -> Section a -> b # foldl' :: (b -> a -> b) -> b -> Section a -> b # foldr1 :: (a -> a -> a) -> Section a -> a # foldl1 :: (a -> a -> a) -> Section a -> a # toList :: Section a -> [a] # null :: Section a -> Bool # length :: Section a -> Int # elem :: Eq a => a -> Section a -> Bool # maximum :: Ord a => Section a -> a # minimum :: Ord a => Section a -> a # sum :: Num a => Section a -> a # product :: Num a => Section a -> a #
Traversable Section # |
Instance details Defined in Hpack.Config Methods traverse :: Applicative f => (a -> f b) -> Section a -> f (Section b) # sequenceA :: Applicative f => Section (f a) -> f (Section a) # mapM :: Monad m => (a -> m b) -> Section a -> m (Section b) # sequence :: Monad m => Section (m a) -> m (Section a) #
Show a => Show (Section a) # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Section a -> ShowS # show :: Section a -> String # showList :: [Section a] -> ShowS #
Eq a => Eq (Section a) # |
Instance details Defined in Hpack.Config Methods (==) :: Section a -> Section a -> Bool # (/=) :: Section a -> Section a -> Bool #

data Library #

Constructors

Library |
Fields libraryExposed :: Maybe Bool libraryVisibility :: Maybe String libraryExposedModules :: [Module] libraryOtherModules :: [Module] libraryGeneratedModules :: [Module] libraryReexportedModules :: [String] librarySignatures :: [String]

#### Instances

Instances details

Show Library # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Library -> ShowS # show :: Library -> String # showList :: [Library] -> ShowS #
Eq Library # |
Instance details Defined in Hpack.Config Methods (==) :: Library -> Library -> Bool # (/=) :: Library -> Library -> Bool #

data Executable #

Constructors

Executable |
Fields executableMain :: Maybe FilePath executableOtherModules :: [Module] executableGeneratedModules :: [Module]

#### Instances

Instances details

Show Executable # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Executable -> ShowS # show :: Executable -> String # showList :: [Executable] -> ShowS #
Eq Executable # |
Instance details Defined in Hpack.Config Methods (==) :: Executable -> Executable -> Bool # (/=) :: Executable -> Executable -> Bool #

data Conditional a #

Constructors

Conditional |
Fields conditionalCondition :: Cond conditionalThen :: a conditionalElse :: Maybe a

#### Instances

Instances details

Functor Conditional # |
Instance details Defined in Hpack.Config Methods fmap :: (a -> b) -> Conditional a -> Conditional b # (<$) :: a -> Conditional b -> Conditional a #
Foldable Conditional # |
Instance details Defined in Hpack.Config Methods fold :: Monoid m => Conditional m -> m # foldMap :: Monoid m => (a -> m) -> Conditional a -> m # foldMap' :: Monoid m => (a -> m) -> Conditional a -> m # foldr :: (a -> b -> b) -> b -> Conditional a -> b # foldr' :: (a -> b -> b) -> b -> Conditional a -> b # foldl :: (b -> a -> b) -> b -> Conditional a -> b # foldl' :: (b -> a -> b) -> b -> Conditional a -> b # foldr1 :: (a -> a -> a) -> Conditional a -> a # foldl1 :: (a -> a -> a) -> Conditional a -> a # toList :: Conditional a -> [a] # null :: Conditional a -> Bool # length :: Conditional a -> Int # elem :: Eq a => a -> Conditional a -> Bool # maximum :: Ord a => Conditional a -> a # minimum :: Ord a => Conditional a -> a # sum :: Num a => Conditional a -> a # product :: Num a => Conditional a -> a #
Traversable Conditional # |
Instance details Defined in Hpack.Config Methods traverse :: Applicative f => (a -> f b) -> Conditional a -> f (Conditional b) # sequenceA :: Applicative f => Conditional (f a) -> f (Conditional a) # mapM :: Monad m => (a -> m b) -> Conditional a -> m (Conditional b) # sequence :: Monad m => Conditional (m a) -> m (Conditional a) #
Show a => Show (Conditional a) # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Conditional a -> ShowS # show :: Conditional a -> String # showList :: [Conditional a] -> ShowS #
Eq a => Eq (Conditional a) # |
Instance details Defined in Hpack.Config Methods (==) :: Conditional a -> Conditional a -> Bool # (/=) :: Conditional a -> Conditional a -> Bool #

data Cond #

Constructors

CondBool Bool |
CondExpression String |

#### Instances

Instances details

Show Cond # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Cond -> ShowS # show :: Cond -> String # showList :: [Cond] -> ShowS #
Eq Cond # |
Instance details Defined in Hpack.Config Methods (==) :: Cond -> Cond -> Bool # (/=) :: Cond -> Cond -> Bool #
FromValue Cond # |
Instance details Defined in Hpack.Config Methods fromValue :: Value -> Parser Cond #

data Flag #

Constructors

Flag |
Fields flagName :: String flagDescription :: Maybe String flagManual :: Bool flagDefault :: Bool

#### Instances

Instances details

Show Flag # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Flag -> ShowS # show :: Flag -> String # showList :: [Flag] -> ShowS #
Eq Flag # |
Instance details Defined in Hpack.Config Methods (==) :: Flag -> Flag -> Bool # (/=) :: Flag -> Flag -> Bool #

data SourceRepository #

Constructors

SourceRepository |
Fields sourceRepositoryUrl :: String sourceRepositorySubdir :: Maybe String

#### Instances

Instances details

Show SourceRepository # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> SourceRepository -> ShowS # show :: SourceRepository -> String # showList :: [SourceRepository] -> ShowS #
Eq SourceRepository # |
Instance details Defined in Hpack.Config Methods (==) :: SourceRepository -> SourceRepository -> Bool # (/=) :: SourceRepository -> SourceRepository -> Bool #

newtype Language #

Constructors

Language String |

#### Instances

Instances details

IsString Language # |
Instance details Defined in Hpack.Config Methods fromString :: String -> Language #
Show Language # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Language -> ShowS # show :: Language -> String # showList :: [Language] -> ShowS #
Eq Language # |
Instance details Defined in Hpack.Config Methods (==) :: Language -> Language -> Bool # (/=) :: Language -> Language -> Bool #
FromValue Language # |
Instance details Defined in Hpack.Config Methods fromValue :: Value -> Parser Language #

data BuildType #

Constructors

Simple |
Configure |
Make |
Custom |

#### Instances

Instances details

Bounded BuildType # |
Instance details Defined in Hpack.Config Methods minBound :: BuildType # maxBound :: BuildType #
Enum BuildType # |
Instance details Defined in Hpack.Config Methods succ :: BuildType -> BuildType # pred :: BuildType -> BuildType # toEnum :: Int -> BuildType # fromEnum :: BuildType -> Int # enumFrom :: BuildType -> [BuildType] # enumFromThen :: BuildType -> BuildType -> [BuildType] # enumFromTo :: BuildType -> BuildType -> [BuildType] # enumFromThenTo :: BuildType -> BuildType -> BuildType -> [BuildType] #
Show BuildType # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> BuildType -> ShowS # show :: BuildType -> String # showList :: [BuildType] -> ShowS #
Eq BuildType # |
Instance details Defined in Hpack.Config Methods (==) :: BuildType -> BuildType -> Bool # (/=) :: BuildType -> BuildType -> Bool #
FromValue BuildType # |
Instance details Defined in Hpack.Config Methods fromValue :: Value -> Parser BuildType #

type GhcProfOption = String #

type GhcjsOption = String #

type CppOption = String #

type AsmOption = String #

type CcOption = String #

type LdOption = String #

newtype Path #

Constructors

Path |
Fields unPath :: FilePath

#### Instances

Instances details

IsString Path # |
Instance details Defined in Hpack.Config Methods fromString :: String -> Path #
Show Path # |
Instance details Defined in Hpack.Config Methods showsPrec :: Int -> Path -> ShowS # show :: Path -> String # showList :: [Path] -> ShowS #
Eq Path # |
Instance details Defined in Hpack.Config Methods (==) :: Path -> Path -> Bool # (/=) :: Path -> Path -> Bool #
Ord Path # |
Instance details Defined in Hpack.Config Methods compare :: Path -> Path -> Ordering # (<) :: Path -> Path -> Bool # (<=) :: Path -> Path -> Bool # (>) :: Path -> Path -> Bool # (>=) :: Path -> Path -> Bool # max :: Path -> Path -> Path # min :: Path -> Path -> Path #

newtype Module #

Constructors

Module |
Fields unModule :: String

#### Instances

Instances details

IsString Module # |
Instance details Defined in Hpack.Module Methods fromString :: String -> Module #
Show Module # |
Instance details Defined in Hpack.Module Methods showsPrec :: Int -> Module -> ShowS # show :: Module -> String # showList :: [Module] -> ShowS #
Eq Module # |
Instance details Defined in Hpack.Module Methods (==) :: Module -> Module -> Bool # (/=) :: Module -> Module -> Bool #
Ord Module # |
Instance details Defined in Hpack.Module Methods compare :: Module -> Module -> Ordering # (<) :: Module -> Module -> Bool # (<=) :: Module -> Module -> Bool # (>) :: Module -> Module -> Bool # (>=) :: Module -> Module -> Bool # max :: Module -> Module -> Module # min :: Module -> Module -> Module #
FromValue Module # |
Instance details Defined in Hpack.Module Methods fromValue :: Value -> Parser Module #