packages

package
v0.0.0-...-c4e951e Latest Latest
Warning

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

Go to latest
Published: May 5, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Overview

Packages contains utilities for interacting with Gentoo packages.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Metadata

type Metadata struct {
	parser.PackageCommon

	// Name is the name of the package as calculated from the PF.
	Name string
	// Version is the version of the package as calculated from the PF.
	Version string

	CBuild        string
	CFlags        string
	CHost         string
	CXX           string
	CXXFlags      string
	Category      string
	Description   string
	Features      []string
	IUseEffective string
	Inherited     []string
	LDFLAGS       string
	PF            string
}

Metadata is the representation of a metadata.tar from a gpkg.

type Package

type Package struct {
	// Metadata contains package fields from a metadata.tar of a gpkg.
	Metadata
	// contains filtered or unexported fields
}

Package represents a Gentoo gpkg (xpkg is not supported).

func New

func New(r io.Reader) (*Package, error)

New creates a new Package from the provided io.ReadCloser. The provided ReadCloser should be streaming the raw contents of a Gentoo package (gpkg).

The package will be stored on disk in a temporary directory due to the nature of gpkgs being usually a large tarball.

func (*Package) Delete

func (p *Package) Delete() error

Delete removes the package from disk.

Jump to

Keyboard shortcuts

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