Find the package category automatically
Some checks failed
Build / audit (push) Successful in 14m43s
Build / test (push) Failing after 5m37s

This commit is contained in:
2024-02-17 14:15:01 +01:00
parent c8643a2fd4
commit 1094ba7a33
2 changed files with 54 additions and 48 deletions

View File

@ -6,7 +6,8 @@ module SlackBuilder.Package
( DownloadPlaceholder(..)
, Download(..)
, DownloadTemplate(..)
, Package(..)
, PackageDescription(..)
, PackageUpdateData(..)
, Maintainer(..)
, Updater(..)
, renderDownloadWithVersion
@ -23,13 +24,18 @@ import Control.Monad.Catch (MonadThrow)
import Data.Map (Map)
-- | Contains information how a package can be updated.
data Package = Package
data PackageDescription = PackageDescription
{ latest :: Updater
, downloaders :: Map Text Updater
, category :: Text
, name :: Text
}
data PackageUpdateData = PackageUpdateData
{ description :: PackageDescription
, category :: Text
, version :: Text
}
-- | Download URI with the MD5 checksum of the target.
data Download = Download
{ download :: URI