module Nix.JenkinsPlugins2Nix.Types
( Manifest(..)
, Plugin(..)
, PluginDependency(..)
, PluginResolution(..)
, RequestedPlugin(..)
) where
import qualified Crypto.Hash as Hash
import Data.Set (Set)
import Data.Text (Text)
data RequestedPlugin = RequestedPlugin
{
requested_name :: !Text
, requested_version :: !(Maybe Text)
} deriving (Show, Eq, Ord)
data PluginResolution = Mandatory | Optional
deriving (Show, Eq, Ord)
data PluginDependency = PluginDependency
{
plugin_dependency_resolution :: !PluginResolution
, plugin_dependency_name :: !Text
, plugin_dependency_version :: !Text
} deriving (Show, Eq, Ord)
data Plugin = Plugin
{
download_url :: !Text
, sha256 :: !(Hash.Digest Hash.SHA256)
, manifest :: !Manifest
} deriving (Show, Eq, Ord)
data Manifest = Manifest
{
manifest_version :: !Text
, archiver_version :: !(Maybe Text)
, created_by :: !(Maybe Text)
, built_by :: !(Maybe Text)
, build_jdk :: !(Maybe Text)
, extension_name :: !(Maybe Text)
, specification_title :: !(Maybe Text)
, implementation_title :: !(Maybe Text)
, implementation_version :: !(Maybe Text)
, group_id :: !(Maybe Text)
, short_name :: !Text
, long_name :: !Text
, url :: !Text
, plugin_version :: !Text
, hudson_version :: !(Maybe Text)
, jenkins_version :: !(Maybe Text)
, plugin_dependencies :: !(Set PluginDependency)
, plugin_developers :: !(Set Text)
} deriving (Show, Eq, Ord)