mirror of
https://github.com/input-output-hk/foliage.git
synced 2024-09-11 20:27:09 +03:00
Comments and formatting
This commit is contained in:
parent
754a1c1bd7
commit
285c8e31b1
@ -158,6 +158,9 @@ revisionMetaCodec =
|
||||
|
||||
data DeprecationSpec = DeprecationSpec
|
||||
{ deprecationTimestamp :: UTCTime,
|
||||
-- | 'True' means the package version has been deprecated
|
||||
-- 'False' means the package version has been undeprecated
|
||||
-- FIXME: we should consider something better than 'Bool'
|
||||
deprecationIsDeprecated :: Bool
|
||||
}
|
||||
deriving (Show, Eq, Generic, Ord)
|
||||
|
@ -187,9 +187,19 @@ preparePackageVersion inputDir metaFile = do
|
||||
"version in cabal file: " ++ prettyShow (Distribution.Types.PackageId.pkgVersion $ package $ packageDescription pkgDesc)
|
||||
]
|
||||
|
||||
let cabalFileRevisions = sortOn Down [(revisionTimestamp, cabalFileRevisionPath revisionNumber) | RevisionSpec {revisionTimestamp, revisionNumber} <- packageVersionRevisions pkgSpec]
|
||||
let cabalFileRevisions =
|
||||
sortOn
|
||||
Down
|
||||
[ (revisionTimestamp, cabalFileRevisionPath revisionNumber)
|
||||
| RevisionSpec {revisionTimestamp, revisionNumber} <- packageVersionRevisions pkgSpec
|
||||
]
|
||||
|
||||
let pkgVersionDeprecationChanges = sortOn Down [(deprecationTimestamp, deprecationIsDeprecated) | DeprecationSpec {deprecationTimestamp, deprecationIsDeprecated} <- packageVersionDeprecations pkgSpec]
|
||||
let pkgVersionDeprecationChanges =
|
||||
sortOn
|
||||
Down
|
||||
[ (deprecationTimestamp, deprecationIsDeprecated)
|
||||
| DeprecationSpec {deprecationTimestamp, deprecationIsDeprecated} <- packageVersionDeprecations pkgSpec
|
||||
]
|
||||
|
||||
let pkgVersionIsDeprecated = maybe False snd $ listToMaybe pkgVersionDeprecationChanges
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user