Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrMissingControl is a missing control error. ErrMissingControl = errors.New("missing control") // ErrMissingControlDescription is a missing control description error. ErrMissingControlDescription = errors.New("missing control description") // ErrMissingDescription is a missing description error. ErrMissingDescription = errors.New("missing description") // ErrMissingInstall is a missing install error. ErrMissingInstall = errors.New("missing install") // ErrMissingMaintainer is a missing maintainer error. ErrMissingMaintainer = errors.New("missing maintainer") // ErrMissingName is a missing name error. ErrMissingName = errors.New("missing name") // ErrMissingSource is a missing source error. ErrMissingSource = errors.New("missing source") // ErrMissingSourceURL is a missing source URL error. ErrMissingSourceURL = errors.New("missing source URL") // ErrUnsupportedVersion is an unsupported version error. ErrUnsupportedVersion = errors.New("unsupported version") )
Functions ¶
Types ¶
type Control ¶
type Control struct { Section string `yaml:"section"` Priority string `yaml:"priority"` Version struct { Epoch uint `yaml:"epoch"` } `yaml:"version"` Depends []string `yaml:"depends"` PreDepends []string `yaml:"pre-depends"` Recommends []string `yaml:"recommends"` Suggests []string `yaml:"suggests"` Enhances []string `yaml:"enhances"` Breaks []string `yaml:"breaks"` Conflicts []string `yaml:"conflicts"` Description string `yaml:"description"` }
Control is a recipe control.
type Install ¶
type Install struct { Recipe InstallMap `yaml:"recipe"` Upstream InstallMap `yaml:"upstream"` }
Install is a recipe installation.
type InstallRule ¶
type InstallRule struct { Pattern string `yaml:"pattern"` Exclude string `yaml:"exclude"` Rename string `yaml:"rename"` ConfFile bool `yaml:"conffile"` }
InstallRule is a recipe installation rule.
type Recipe ¶
type Recipe struct { Version int `yaml:"version"` Name string `yaml:"name"` Description string `yaml:"description"` Maintainer string `yaml:"maintainer"` Homepage string `yaml:"homepage"` Source *Source `yaml:"source"` Control *Control `yaml:"control"` Install *Install `yaml:"install"` Dirs []string `yaml:"dirs"` Links map[string]string `yaml:"links"` ControlFiles []File RecipeFiles []File }
Recipe is a packaging recipe.
func LoadRecipe ¶
LoadRecipe loads a packaging recipe given a file path.
func (*Recipe) InstallPath ¶
InstallPath returns the destination installation path, whether it matches a configuration file path.
Last returned boolean will be false if the input path doesn't match the installation rules and true otherwise.
Click to show internal directories.
Click to hide internal directories.