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


-- | Check your cabal packages for lagging dependencies.
--   
--   This provides a library and command line tool for checking if the
--   upper bounds in your package's dependency list excludes the newest
--   package available. The code was originally available only as a web
--   interface at <a>http://packdeps.haskellers.com/</a>, but is now
--   available for standalone use as well.
--   
--   The command line tool has an incredibly simple interface: simply pass
--   it a list of cabal files, and it will tell you what dependencies- if
--   any- are restricted.
@package packdeps
@version 0.4.5

module Distribution.PackDeps

-- | The newest version of every package.
type Newest = Map PackageName PackInfo

-- | Whether or not a package can accept all of the newest versions of its
--   dependencies. If not, it returns a list of packages which are not
--   accepted, and a timestamp of the most recently updated package.
data CheckDepsRes
AllNewest :: CheckDepsRes
WontAccept :: [(PackageName, Version)] -> UTCTime -> CheckDepsRes

-- | Information on a single package.
data DescInfo
loadNewest :: Bool -> IO Newest

-- | Takes a list of possible pathes, tries them in order until one exists.
loadNewestFrom :: Bool -> [FilePath] -> IO Newest
parseNewest :: Bool -> ByteString -> Newest
checkDeps :: Newest -> DescInfo -> (PackageName, Version, CheckDepsRes)
checkLibDeps :: Newest -> DescInfo -> (PackageName, Version, CheckDepsRes)

-- | Loads up the newest version of a package from the <a>Newest</a> list,
--   if available.
getPackage :: PackageName -> Newest -> Maybe DescInfo

-- | Parse information on a package from the contents of a cabal file.
parsePackage :: ByteString -> Maybe DescInfo

-- | Load a single package from a cabal file.
loadPackage :: FilePath -> IO (Maybe DescInfo)

-- | Find all of the packages matching a given search string.
filterPackages :: String -> Newest -> [DescInfo]

-- | Find all packages depended upon by the given list of packages.
deepDeps :: Newest -> [DescInfo] -> [DescInfo]

-- | Find all packages depended upon by the given list of packages.
deepLibDeps :: Newest -> [DescInfo] -> [DescInfo]
type Reverses = Map PackageName (Version, [(PackageName, VersionRange)])
getReverses :: Newest -> Reverses
diName :: DescInfo -> String
data PackInfo
PackInfo :: !Version -> Maybe DescInfo -> !EpochTime -> PackInfo
[piVersion] :: PackInfo -> !Version
[piDesc] :: PackInfo -> Maybe DescInfo
[piEpoch] :: PackInfo -> !EpochTime
piRevision :: PackInfo -> Int

-- | Information on a single package.
data DescInfo
DescInfo :: String -> [Dependency] -> [Dependency] -> PackageIdentifier -> Int -> String -> DescInfo
[diHaystack] :: DescInfo -> String
[diDeps] :: DescInfo -> [Dependency]
[diLibDeps] :: DescInfo -> [Dependency]
[diPackage] :: DescInfo -> PackageIdentifier
[diRevision] :: DescInfo -> Int
[diSynopsis] :: DescInfo -> String
instance GHC.Show.Show Distribution.PackDeps.CheckDepsRes
instance GHC.Read.Read Distribution.PackDeps.PackInfo
instance GHC.Show.Show Distribution.PackDeps.PackInfo
instance GHC.Read.Read Distribution.PackDeps.DescInfo
instance GHC.Show.Show Distribution.PackDeps.DescInfo
