Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module provides simple dependency graph making for rpm packages:
import Distribution.RPM.Build.Graph
graph <- createGraph
["pkg1", "pkg2", "../pkg3"]
Synopsis
- type PackageGraph = Gr FilePath ()
- createGraph :: [FilePath] -> IO PackageGraph
- createGraphRpmOpts :: [String] -> [FilePath] -> IO PackageGraph
- createGraph' :: Bool -> Bool -> Bool -> Maybe FilePath -> [FilePath] -> IO PackageGraph
- createGraph'' :: [String] -> Bool -> Bool -> Bool -> Maybe FilePath -> [FilePath] -> IO PackageGraph
- createGraph''' :: [String] -> [String] -> Bool -> Bool -> Bool -> Maybe FilePath -> [FilePath] -> IO PackageGraph
- dependencyNodes :: [FilePath] -> PackageGraph -> [FilePath]
- subgraph' :: Gr a b -> [Node] -> Gr a b
- packageLayers :: PackageGraph -> [[FilePath]]
- lowestLayer :: PackageGraph -> [FilePath]
- lowestLayer' :: PackageGraph -> [LNode FilePath]
- packageLeaves :: PackageGraph -> [FilePath]
- separatePackages :: PackageGraph -> [FilePath]
Documentation
type PackageGraph = Gr FilePath () Source #
alias for a package dependency graph
:: [FilePath] | package paths (directories or spec filepaths) |
-> IO PackageGraph | dependency graph labelled by package paths |
Create a directed dependency graph for a set of packages This is a convenience wrapper for createGraph' False False True Nothing
:: [String] | rpmspec options |
-> [FilePath] | package paths (directories or spec filepaths) |
-> IO PackageGraph | dependency graph labelled by package paths |
Create a directed dependency graph for a set of packages setting rpm options
This is a convenience wrapper for createGraph'' rpmopts False False True Nothing
Since: 0.4.2
:: Bool | verbose |
-> Bool | lenient (skip rpmspec failures) |
-> Bool | reverse dependency graph |
-> Maybe FilePath | look for spec file in a subdirectory |
-> [FilePath] | package paths (directories or spec filepaths) |
-> IO PackageGraph | dependency graph labelled by package paths |
Create a directed dependency graph for a set of packages For the (createGraph default) reverse deps graph the arrows point back from the dependencies to the dependendent (parent/consumer) packages, and this allows forward sorting by dependencies (ie lowest deps first).
This is the same as createGraph'' []
:: [String] | rpmspec options |
-> Bool | verbose |
-> Bool | lenient (skip rpmspec failures) |
-> Bool | reverse dependency graph |
-> Maybe FilePath | look for spec file in a subdirectory |
-> [FilePath] | package paths (directories or spec filepaths) |
-> IO PackageGraph | dependency graph labelled by package paths |
Create a directed dependency graph for a set of packages For the (createGraph default) reverse deps graph the arrows point back from the dependencies to the dependendent (parent/consumer) packages, and this allows forward sorting by dependencies (ie lowest deps first).
Additionally this function allows passing options to rpmspec: eg `--with bootstrap` etc
Since: 0.4.2
:: [String] | ignored BuildRequires |
-> [String] | rpmspec options |
-> Bool | verbose |
-> Bool | lenient (skip rpmspec failures) |
-> Bool | reverse dependency graph |
-> Maybe FilePath | look for spec file in a subdirectory |
-> [FilePath] | package paths (directories or spec filepaths) |
-> IO PackageGraph | dependency graph labelled by package paths |
Create a directed dependency graph for a set of packages
Like createGraph'' but with additional parameter for any BRs to be ignored.
Since: 0.4.3
:: [FilePath] | subset of packages to start from |
-> PackageGraph | dependency graph |
-> [FilePath] | dependencies of subset |
Get all of the dependencies of a subset of one or more packages within full PackageGraph. The subset paths should be written in the same way as for the graph.
packageLayers :: PackageGraph -> [[FilePath]] Source #
Return the bottom-up list of dependency layers of a graph
lowestLayer :: PackageGraph -> [FilePath] Source #
The lowest dependencies of a PackageGraph
lowestLayer' :: PackageGraph -> [LNode FilePath] Source #
The lowest dependency nodes of a PackageGraph
packageLeaves :: PackageGraph -> [FilePath] Source #
The leaf (outer) packages of a PackageGraph
separatePackages :: PackageGraph -> [FilePath] Source #
Returns packages independent of all the rest of the graph