apt

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractVersion added in v0.5.0

func ExtractVersion(input string) string

ExtractVersion extracts version value from the output of dpkg -s <package>.

func FindInstalled

func FindInstalled(ctx context.Context, name string) (string, error)

func Install

func Install(ctx context.Context, name string) error

func Uninstall

func Uninstall(ctx context.Context, name string) error

Types

type Info added in v0.5.0

type Info struct {
	Name    string
	Version string
}

Info contains the package name and the package version.

func GetInfo added in v0.5.0

func GetInfo(original string) Info

GetInfo splits the name and version from string name=version and put the values into Info.

Jump to

Keyboard shortcuts

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