debian

package
v0.0.0-...-a8e8087 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

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

func (d *Package) ComputeSize(sourceDir string) (int64, error)

ComputeSize returns size of a directory

func (*Package) CopyResults

func (d *Package) CopyResults(from string, to string) error

CopyResults copy the packages to the path..

func (*Package) GenerateFiles

func (d *Package) GenerateFiles(sourceDir string, pkgDir string) error

GenerateFiles from sourceDir to pkgDir

func (*Package) GenerateInstall

func (d *Package) GenerateInstall(sourceDir string, debianDir string, dataDir string) error

GenerateInstall generates install file.

func (*Package) ImportFiles

func (d *Package) ImportFiles(sourceDir string) error

ImportFiles add files to the package.

func (*Package) Load

func (d *Package) Load(file string) error

Load given deb.json file

func (*Package) Normalize

func (d *Package) Normalize(debianDir string, version string, arch string)

Normalize current metadata

func (*Package) WriteChangelogFile

func (d *Package) WriteChangelogFile(debianDir string) error

WriteChangelogFile writes the changelog file.

func (*Package) WriteConffiles

func (d *Package) WriteConffiles(debianDir string) error

WriteConffiles updates the debian directory

func (*Package) WriteControlFile

func (d *Package) WriteControlFile(debianDir string, size uint64) error

WriteControlFile writes the control file.

func (*Package) WriteCopyrightFile

func (d *Package) WriteCopyrightFile(debianDir string) error

WriteCopyrightFile writes the copyright file.

func (*Package) WriteCronFiles

func (d *Package) WriteCronFiles(debianDir string) error

WriteCronFiles writes the cron file.

func (*Package) WriteDefaultInitFile

func (d *Package) WriteDefaultInitFile(dataDir string) error

WriteDefaultInitFile writes the etc/default file.

func (*Package) WriteEnvProfile

func (d *Package) WriteEnvProfile(debianDir string) error

WriteEnvProfile generates an etc/profile.d/plg.name.sh

func (*Package) WriteInitFile

func (d *Package) WriteInitFile(dataDir string) error

WriteInitFile writes the etc/init.d file.

func (*Package) WriteManPageIndexFile

func (d *Package) WriteManPageIndexFile(debianDir string) error

WriteManPageIndexFile writes the map page index file.

func (*Package) WritePostInstFile

func (d *Package) WritePostInstFile(debianDir string) error

WritePostInstFile writes the postinst file.

func (*Package) WritePostRmFile

func (d *Package) WritePostRmFile(debianDir string) error

WritePostRmFile writes the postrm file.

func (*Package) WritePreInstFile

func (d *Package) WritePreInstFile(debianDir string) error

WritePreInstFile writes the preinst file.

func (*Package) WritePreRmFile

func (d *Package) WritePreRmFile(debianDir string) error

WritePreRmFile writes the prerm file.

func (*Package) WriteShortcuts

func (d *Package) WriteShortcuts(dataDir string) error

WriteShortcuts writes the application shortcuts.

func (*Package) WriteUnitFile

func (d *Package) WriteUnitFile(dataDir string) error

WriteUnitFile writes the unit.d file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL