PKG-UPDATE(8)

NAME
pkg update - update the local catalogues of the enabled package repositories

SYNOPSIS
pkg update [-fq] [-r reponame]

pkg update [--{force,quiet}] [--repository reponame]

DESCRIPTION
pkg update is used for updating the local copy of the repository catalogues from the remote package repository databases. Updates to catalogues are normally downloaded only when the master copy on the remote package repository is newer than the local copy.

The repository catalogues to be updated are defined in the pkg.conf(5) file or by the entries in /usr/pkg/etc/pkg/repos. See pkg.conf(5) for details.

It is best practice to ensure your package repository catalogues are up to date before doing any package installation (via pkg-install(8)) or upgrades (via pkg-upgrade(8)). However, explicitly running pkg update is not normally necessary. By default invoking either of pkg install or pkg upgrade will cause repository catalogues to be updated automatically, unless disabled by setting REPO_AUTOUPDATE to false in pkg.conf(5).

  Signed repositories
If the repository catalogue is signed and PUBKEY is defined for the repository, the signature will be verified after download. See pkg.conf(5) for more information.

OPTIONS
The following options are supported by pkg update:

-q, --quiet
    Force quiet output.

-f, --force
    Force a full download of the repository catalogue without regard to the respective ages of the local and remote copies of the catalogue.

-r reponame, --repository reponame
    Download the catalogue for the named repository only. This will update only the named repository, irrespective of the configured “active” status from repo.conf.

ENVIRONMENT
The following environment variables affect the execution of pkg update. See pkg.conf(5) for further description.

PKG_DBDIR

REPO_AUTOUPDATE

FILES
See pkg.conf(5).

SEE ALSO
pkg_printf(3), pkg_repos(3), pkg-repository(5), pkg.conf(5), pkg(8), pkg-add(8), pkg-alias(8), pkg-annotate(8), pkg-audit(8), pkg-autoremove(8), pkg-backup(8), pkg-check(8), pkg-clean(8), pkg-config(8), pkg-create(8), pkg-delete(8), pkg-fetch(8), pkg-info(8), pkg-install(8), pkg-lock(8), pkg-query(8), pkg-register(8), pkg-repo(8), pkg-rquery(8), pkg-search(8), pkg-set(8), pkg-shell(8), pkg-shlib(8), pkg-ssh(8), pkg-stats(8), pkg-updating(8), pkg-upgrade(8), pkg-version(8), pkg-which(8)