alrsh

package
v0.0.34 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2025 License: GPL-3.0 Imports: 24 Imported by: 2

Documentation

Overview

DO NOT EDIT MANUALLY. This file is generated.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PackageToResolved

func PackageToResolved(src *Package) packageResolved

func ResolvePackage

func ResolvePackage(pkg *Package, overrides []string)

Types

type OverridableField

type OverridableField[T any] struct {
	// contains filtered or unexported fields
}

func OverridableFromMap

func OverridableFromMap[T any](data map[string]T) OverridableField[T]

func (*OverridableField[T]) All

func (f *OverridableField[T]) All() map[string]T

func (*OverridableField[T]) FromDB

func (f *OverridableField[T]) FromDB(data []byte) error

func (*OverridableField[T]) Get

func (f *OverridableField[T]) Get(key string) T

func (*OverridableField[T]) GobDecode

func (f *OverridableField[T]) GobDecode(data []byte) error

func (*OverridableField[T]) GobEncode

func (f *OverridableField[T]) GobEncode() ([]byte, error)

func (*OverridableField[T]) Has

func (f *OverridableField[T]) Has(key string) (T, bool)

func (OverridableField[T]) MarshalJSON

func (f OverridableField[T]) MarshalJSON() ([]byte, error)

func (*OverridableField[T]) Resolve

func (o *OverridableField[T]) Resolve(overrides []string)

func (*OverridableField[T]) Resolved

func (f *OverridableField[T]) Resolved() T

func (*OverridableField[T]) Set

func (f *OverridableField[T]) Set(key string, value T)

func (*OverridableField[T]) SetResolved

func (f *OverridableField[T]) SetResolved(value T)

func (*OverridableField[T]) ToDB

func (f *OverridableField[T]) ToDB() ([]byte, error)

Database serialization (JSON)

func (*OverridableField[T]) UnmarshalJSON

func (f *OverridableField[T]) UnmarshalJSON(data []byte) error

type Package

type Package struct {
	Repository  string `xorm:"pk 'repository'" json:"repository"`
	Name        string `xorm:"pk 'name'" json:"name"`
	BasePkgName string `xorm:"notnull 'basepkg_name'" json:"basepkg_name"`

	Version       string   `sh:"version" xorm:"notnull 'version'" json:"version"`
	Release       int      `sh:"release" xorm:"notnull 'release'" json:"release"`
	Epoch         uint     `sh:"epoch" xorm:"'epoch'" json:"epoch"`
	Architectures []string `sh:"architectures" xorm:"json 'architectures'" json:"architectures"`
	Licenses      []string `sh:"license" xorm:"json 'licenses'" json:"license"`
	Provides      []string `sh:"provides" xorm:"json 'provides'" json:"provides"`
	Conflicts     []string `sh:"conflicts" xorm:"json 'conflicts'" json:"conflicts"`
	Replaces      []string `sh:"replaces" xorm:"json 'replaces'" json:"replaces"`

	Summary          OverridableField[string]   `sh:"summary" xorm:"'summary'" json:"summary"`
	Description      OverridableField[string]   `sh:"desc" xorm:"'description'" json:"description"`
	Group            OverridableField[string]   `sh:"group" xorm:"'group_name'" json:"group"`
	Homepage         OverridableField[string]   `sh:"homepage" xorm:"'homepage'" json:"homepage"`
	Maintainer       OverridableField[string]   `sh:"maintainer" xorm:"'maintainer'" json:"maintainer"`
	Depends          OverridableField[[]string] `sh:"deps" xorm:"'depends'" json:"deps"`
	BuildDepends     OverridableField[[]string] `sh:"build_deps" xorm:"'builddepends'" json:"build_deps"`
	OptDepends       OverridableField[[]string] `sh:"opt_deps" xorm:"'optdepends'" json:"opt_deps,omitempty"`
	Sources          OverridableField[[]string] `sh:"sources" xorm:"-" json:"sources"`
	Checksums        OverridableField[[]string] `sh:"checksums" xorm:"-" json:"checksums,omitempty"`
	Backup           OverridableField[[]string] `sh:"backup" xorm:"-" json:"backup"`
	Scripts          OverridableField[Scripts]  `sh:"scripts" xorm:"-" json:"scripts,omitempty"`
	AutoReq          OverridableField[[]string] `sh:"auto_req" xorm:"-" json:"auto_req"`
	AutoProv         OverridableField[[]string] `sh:"auto_prov" xorm:"-" json:"auto_prov"`
	AutoReqSkipList  OverridableField[[]string] `sh:"auto_req_skiplist" xorm:"-" json:"auto_req_skiplist,omitempty"`
	AutoProvSkipList OverridableField[[]string] `sh:"auto_prov_skiplist" xorm:"-" json:"auto_prov_skiplist,omitempty"`

	FireJailed       OverridableField[bool]              `sh:"firejailed" xorm:"-" json:"firejailed"`
	FireJailProfiles OverridableField[map[string]string] `sh:"firejail_profiles" xorm:"-" json:"firejail_profiles,omitempty"`
}

func (Package) MarshalJSONWithOptions

func (p Package) MarshalJSONWithOptions(includeOverrides bool) ([]byte, error)

type PackageNames

type PackageNames struct {
	BasePkgName string   `sh:"basepkg_name"`
	Names       []string `sh:"name"`
}

func ParseNames

func ParseNames(dec *decoder.Decoder) (*PackageNames, error)

type PackageView

type PackageView struct {
	Resolved bool
	// contains filtered or unexported fields
}

func NewPackageView

func NewPackageView(v Package) PackageView

func (PackageView) MarshalJSON

func (p PackageView) MarshalJSON() ([]byte, error)

type ScriptFile

type ScriptFile struct {
	// contains filtered or unexported fields
}

func ReadFromFS

func ReadFromFS(fsys fs.FS, script string) (*ScriptFile, error)

func ReadFromIOReader

func ReadFromIOReader(r io.Reader, script string) (*ScriptFile, error)

func ReadFromLocal

func ReadFromLocal(script string) (*ScriptFile, error)

func (*ScriptFile) File

func (a *ScriptFile) File() *syntax.File

func (*ScriptFile) GobDecode

func (s *ScriptFile) GobDecode(data []byte) error

func (*ScriptFile) GobEncode

func (s *ScriptFile) GobEncode() ([]byte, error)

func (*ScriptFile) ParseBuildVars

func (s *ScriptFile) ParseBuildVars(ctx context.Context, info *distro.OSRelease, packages []string) (string, []*Package, error)

func (*ScriptFile) Path

func (a *ScriptFile) Path() string

type Scripts

type Scripts struct {
	PreInstall  string `sh:"preinstall"`
	PostInstall string `sh:"postinstall"`
	PreRemove   string `sh:"preremove"`
	PostRemove  string `sh:"postremove"`
	PreUpgrade  string `sh:"preupgrade"`
	PostUpgrade string `sh:"postupgrade"`
	PreTrans    string `sh:"pretrans"`
	PostTrans   string `sh:"posttrans"`
}

Jump to

Keyboard shortcuts

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