Documentation ¶
Index ¶
- type Package
- func (d *Package) ComputeSize(sourceDir string) (int64, error)
- func (d *Package) CopyResults(from string, to string) error
- func (d *Package) GenerateFiles(sourceDir string, pkgDir string) error
- func (d *Package) GenerateInstall(sourceDir string, debianDir string, dataDir string) error
- func (d *Package) ImportFiles(sourceDir string) error
- func (d *Package) Load(file string) error
- func (d *Package) Normalize(debianDir string, version string, arch string)
- func (d *Package) WriteChangelogFile(debianDir string) error
- func (d *Package) WriteConffiles(debianDir string) error
- func (d *Package) WriteControlFile(debianDir string, size uint64) error
- func (d *Package) WriteCopyrightFile(debianDir string) error
- func (d *Package) WriteCronFiles(debianDir string) error
- func (d *Package) WriteDefaultInitFile(dataDir string) error
- func (d *Package) WriteEnvProfile(debianDir string) error
- func (d *Package) WriteInitFile(dataDir string) error
- func (d *Package) WriteManPageIndexFile(debianDir string) error
- func (d *Package) WritePostInstFile(debianDir string) error
- func (d *Package) WritePostRmFile(debianDir string) error
- func (d *Package) WritePreInstFile(debianDir string) error
- func (d *Package) WritePreRmFile(debianDir string) error
- func (d *Package) WriteShortcuts(dataDir string) error
- func (d *Package) WriteUnitFile(dataDir string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Package ¶
type Package struct { Name string `json:"name"` // Name of the package Maintainer string `json:"maintainer"` // Information of the package maintainer Changedby string `json:"changed-by"` // Information of the last package maintainer Section string `json:"section"` // Classification of the application area Priority string `json:"priority"` // Priority of the package (required,important,standard,optional,extra) Arch string `json:"arch"` // Arch targeted by the package Homepage string `json:"homepage"` // Url to the homepage of the program SourcesURL string `json:"sources-url"` // Url to the source of the program Version string `json:"version"` // Version of the package Vcs []vcsSrc `json:"vcs"` // Vcs information of the package Files []filesInstruction `json:"files"` // Files information to copy into the package CopyrightSpecURL string `json:"copyrights-spec-url"` // Url to the copyright file specification Copyrights []copyright `json:"copyrights"` // Copyrights of the package Essential bool `json:"essential"` // Indicate if the package is an essential one Depends []string `json:"depends"` // Dependency list Recommends []string `json:"recommends"` // Recommendation list Suggests []string `json:"suggests"` // Suggestion list Enhances []string `json:"enhances"` // Enhancement list PreDepends []string `json:"pre-depends"` // Pre-dependency list Breaks []string `json:"breaks"` // Breaks list Conflicts []string `json:"conflicts"` // Conflicts list Envs map[string]string `json:"envs"` // Environment variables to define Provides string `json:"provides"` // Provides Replaces string `json:"replaces"` // Replaces BuiltUsing string `json:"built-using"` // Built-using list Description string `json:"description"` // A one-line short description DescriptionExtended string `json:"description-extended"` // A multi-line long description PackageType string `json:"package-type"` // Type of the package CronFiles map[string]string `json:"cron-files"` // Cron files to use for the package CronCmds map[string]string `json:"cron-cmds"` // Cron string to use to generate cron files for the package SystemdFile string `json:"systemd-file"` // Systemd unit file InitFile string `json:"init-file"` // Init file describing a service for the package DefaultFile string `json:"default-file"` // Default init file describing a service for the package PreinstFile string `json:"preinst-file"` // Pre-inst script path PostinstFile string `json:"postinst-file"` // Post-inst script path PrermFile string `json:"prerm-file"` // Pre-rm script path PostrmFile string `json:"postrm-file"` // Post-rm script path Conffiles []string `json:"conf-files"` // A list of the configuration files Mans []string `json:"mans"` // A list of man page in the package ChangelogFile string `json:"changelog-file"` // Post-rm to the changelog file to copy to the package ChangelogCmd string `json:"changelog-cmd"` // A cmd to run which generates the content of the changelog file Menus []menu `json:"menus"` // Desktop shortcuts }
Package contaisn informtation about a debian package to build
func (*Package) ComputeSize ¶
ComputeSize returns size of a directory
func (*Package) CopyResults ¶
CopyResults copy the packages to the path..
func (*Package) GenerateFiles ¶
GenerateFiles from sourceDir to pkgDir
func (*Package) GenerateInstall ¶
GenerateInstall generates install file.
func (*Package) ImportFiles ¶
ImportFiles add files to the package.
func (*Package) WriteChangelogFile ¶
WriteChangelogFile writes the changelog file.
func (*Package) WriteConffiles ¶
WriteConffiles updates the debian directory
func (*Package) WriteControlFile ¶
WriteControlFile writes the control file.
func (*Package) WriteCopyrightFile ¶
WriteCopyrightFile writes the copyright file.
func (*Package) WriteCronFiles ¶
WriteCronFiles writes the cron file.
func (*Package) WriteDefaultInitFile ¶
WriteDefaultInitFile writes the etc/default file.
func (*Package) WriteEnvProfile ¶
WriteEnvProfile generates an etc/profile.d/plg.name.sh
func (*Package) WriteInitFile ¶
WriteInitFile writes the etc/init.d file.
func (*Package) WriteManPageIndexFile ¶
WriteManPageIndexFile writes the map page index file.
func (*Package) WritePostInstFile ¶
WritePostInstFile writes the postinst file.
func (*Package) WritePostRmFile ¶
WritePostRmFile writes the postrm file.
func (*Package) WritePreInstFile ¶
WritePreInstFile writes the preinst file.
func (*Package) WritePreRmFile ¶
WritePreRmFile writes the prerm file.
func (*Package) WriteShortcuts ¶
WriteShortcuts writes the application shortcuts.
func (*Package) WriteUnitFile ¶
WriteUnitFile writes the unit.d file.