LinuxCommandLibrary

pkg

FreeBSD binary package manager

TLDR

Install package

$ pkg install [package]
copy
Search packages
$ pkg search [query]
copy
Update package database
$ pkg update
copy
Upgrade packages
$ pkg upgrade
copy
Remove package
$ pkg delete [package]
copy
List installed
$ pkg info
copy

SYNOPSIS

pkg [command] [options] [package...]

DESCRIPTION

pkg is the official binary package manager for FreeBSD. It handles installation, removal, upgrading, and searching of pre-built packages from FreeBSD repositories, replacing the older pkg_add tools.
The tool resolves dependencies automatically, manages a local package database, and supports multiple repositories. It can also lock packages to prevent upgrades, audit installed packages for security vulnerabilities, and create packages from installed ports.

PARAMETERS

install PACKAGE

Install package.
search QUERY
Search packages.
update
Update database.
upgrade
Upgrade packages.
delete PACKAGE
Remove package.
info
Show information.
--help
Display help.

CONFIGURATION

/usr/local/etc/pkg.conf

Main configuration file for pkg behavior and default settings.
/usr/local/etc/pkg/repos/
Repository configuration directory with per-repo .conf files.

CAVEATS

FreeBSD specific. Root required for install. Repository based.

HISTORY

pkg replaced pkg_add as the FreeBSD package manager.

SEE ALSO

pkg-add(8), ports(7)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community