cabal-gild-1.3.1.0: Formats package descriptions.
Safe HaskellSafe-Inferred
LanguageHaskell2010

CabalGild.Unstable.Action.GetCabalVersion

Synopsis

Documentation

fromFields :: [Field a] -> CabalSpecVersion Source #

Gets the Cabal spec version from a list of fields. If multiple fields define the version, the first one is used.

isCabalVersion :: Field a -> Bool Source #

Returns true if the field is named cabal-version.

getFieldLines :: Field a -> Maybe [FieldLine a] Source #

Gets the field lines from a field. If the field is a section, this returns Nothing.

fromFieldLines :: [FieldLine a] -> Maybe SpecVersion Source #

Attempts to parse the given field lines as a Cabal spec version.