-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Library for Fedora release versions
--   
--   This library provides the Branch and Release datatypes and various
--   associated metadata functions for Fedora releases (Fedora and EPEL)
--   needed for packaging development and building. It uses current release
--   data from Fedora Bodhi.
@package fedora-releases
@version 0.1.0


module Distribution.Fedora.Release

-- | Fedora Release data
data Release
Release :: String -> String -> String -> String -> Release
[releaseName] :: Release -> String
[releaseVersion] :: Release -> String
[releaseIdPrefix] :: Release -> String
[releaseBranch] :: Release -> String

-- | Get list of all current Fedora Project releases (from Bodhi)
getReleases :: IO [Release]

-- | Get list of current Fedora Linux releases
getFedoraReleases :: IO [Release]

-- | Get list of current Fedora EPEL releases
getEPELReleases :: IO [Release]
instance GHC.Classes.Eq Distribution.Fedora.Release.Release
instance GHC.Show.Show Distribution.Fedora.Release.Release
instance GHC.Classes.Ord Distribution.Fedora.Release.Release


module Distribution.Fedora.Branch

-- | Branch datatype
--   
--   Branch can be rawhide, or a fedora or epel branch
data Branch
EPEL :: !Int -> Branch
EPELNext :: !Int -> Branch
Fedora :: !Int -> Branch
Rawhide :: Branch

-- | Read a Fedora Branch name
readBranch :: String -> Maybe Branch

-- | Read a Fedora Branch name, otherwise return branch string
eitherBranch :: String -> Either String Branch

-- | Read a Branch name (one of the list of active branches)
--   
--   Similar to eitherActiveBranch but ignores any error string
readActiveBranch :: [Branch] -> String -> Maybe Branch

-- | Read a Branch name (one of the list of active branches)
--   
--   Provides error strings for inactive or unknown branches.
eitherActiveBranch :: [Branch] -> String -> Either String Branch

-- | Returns newer branch than given one from supplied active branches.
--   
--   Branches should be in descending order, eg from getFedoraBranches
newerBranch :: Branch -> [Branch] -> Branch

-- | Returns list of active Fedora branches, including rawhide and EPEL
getFedoraBranches :: IO [Branch]

-- | Returns list of active Fedora branches, excluding rawhide
getFedoraBranched :: IO [Branch]

-- | get newest Fedora branched Release
getLatestFedoraBranch :: IO Branch

-- | Map Branch to Koji destination tag
branchDestTag :: Branch -> String

-- | Get %dist tag for branch
branchDistTag :: Branch -> IO String

-- | Get Release associated with release Branch
branchRelease :: Branch -> IO Release

-- | Default build target associated with a branch
branchTarget :: Branch -> String

-- | separate fedora branches from rest of args
partitionBranches :: [String] -> ([Branch], [String])
instance GHC.Classes.Ord Distribution.Fedora.Branch.Branch
instance GHC.Classes.Eq Distribution.Fedora.Branch.Branch
instance GHC.Show.Show Distribution.Fedora.Branch.Branch
