Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions app/Foliage/CmdImportIndex.hs
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,10 @@ isCabalFile
, Tar.entryContent = Tar.NormalFile contents _
, Tar.entryTime = posixSecondsToUTCTime . fromIntegral -> time
}
| ".cabal" `isSuffixOf` path =
let [pkgName, pkgVersion, _] = splitDirectories path
Just name = simpleParsec pkgName
Just version = simpleParsec pkgVersion
packageId = PackageIdentifier name version
in Just (packageId, contents, time)
| ".cabal" `isSuffixOf` path
, [pkgName, pkgVersion, _] <- splitDirectories path
, Just name <- simpleParsec pkgName
, Just version <- simpleParsec pkgVersion
, packageId <- PackageIdentifier name version =
Just (packageId, contents, time)
isCabalFile _ = Nothing
7 changes: 4 additions & 3 deletions app/Foliage/Meta.hs
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,10 @@ revisionMetaCodec =
data DeprecationSpec = DeprecationSpec
{ deprecationTimestamp :: UTCTime
, deprecationIsDeprecated :: Bool
-- ^ 'True' means the package version has been deprecated
-- 'False' means the package version has been undeprecated
-- FIXME: we should consider something better than 'Bool'
{- ^ 'True' means the package version has been deprecated
'False' means the package version has been undeprecated
FIXME: we should consider something better than 'Bool'
-}
}
deriving (Show, Eq, Generic, Ord)
deriving anyclass (Binary, Hashable, NFData)
Expand Down
10 changes: 5 additions & 5 deletions app/Foliage/Pages.hs
Original file line number Diff line number Diff line change
Expand Up @@ -130,11 +130,11 @@ makeAllPackageVersionsPage currentTime outputDir packageVersions =
}
-- list of revisions
: [ AllPackageVersionsPageEntryRevision
{ allPackageVersionsPageEntryPkgId = pkgId
, allPackageVersionsPageEntryTimestamp = revisionTimestamp
, allPackageVersionsPageEntryTimestampPosix = utcTimeToPOSIXSeconds revisionTimestamp
, allPackageVersionsPageEntryDeprecated = pkgVersionIsDeprecated
}
{ allPackageVersionsPageEntryPkgId = pkgId
, allPackageVersionsPageEntryTimestamp = revisionTimestamp
, allPackageVersionsPageEntryTimestampPosix = utcTimeToPOSIXSeconds revisionTimestamp
, allPackageVersionsPageEntryDeprecated = pkgVersionIsDeprecated
}
| (revisionTimestamp, _) <- cabalFileRevisions
]
)
Expand Down
4 changes: 2 additions & 2 deletions cabal.project
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
packages: .
index-state: 2023-09-10T21:31:08Z
with-compiler: ghc-9.4.8
index-state: 2025-12-23T23:59:20Z
with-compiler: ghc-9.8.4

tests: True
test-show-details: direct
Loading
Loading