New to FORGE? Start a free 30-day trial

Update Command

Updated on Oct 5, 2026

frg update replaces your frg binary with a newer published release. Use it to upgrade in place instead of reinstalling. The same update path is used when auto_update is enabled.

Prerequisites

  • Network access to GitHub Releases.
  • Write access to the directory that contains the frg binary.
  • No license or coding agent is required.

Subcommands at a glance

frg update has no subcommands. Its behavior is controlled by options and by the [update_check] configuration section.

Setting or optionWhat it doesDefault
frg updateInstalls the newest release that matches your settingsNewest stable release
[update_check] include_prereleaseLets "newest release" include pre-releasesNot set (stable only)
[update_check] auto_updateInstalls available updates automatically after a command completesNot set (notify only)
FORGE_NO_UPDATE_CHECKDisables update checksNot set

See Update Check Configuration for the full description of these settings.

Typical flow

text
update notice (stderr) ──► frg update ──► download to staging file ──► verify ──► atomic swap ──► frg --version
  1. Forge prints a notice on stderr when a newer release is available.
  2. Upgrade:
bash
frg update
  1. Confirm the new version:
bash
frg --version
  1. Optionally, opt in to automatic updates or pre-releases in your configuration:
toml
[update_check]
auto_update = true
include_prerelease = true

frg update

text
frg update [OPTIONS]
OptionDescription
--version <VERSION>Installs a specific published version, regardless of include_prerelease.
--forceReinstalls even if the installed version is current.
bash
frg update
frg update --version <version>

How it works

The self-update library has these properties:

  • The release asset is downloaded to a staged file next to the current binary, created exclusively so that concurrent runs cannot share it.
  • The staged binary replaces the current one in an atomic stage-and-swap, so an interrupted update does not leave a partial binary.
  • Artifact cleanup keeps the active staged binary.
  • With auto_update enabled, updates run after your command completes and take effect on the next command.
  • The update notice is throttled, and suppressed update checks are not cached.

Package manager installations

If a package manager installed frg, upgrade through that package manager:

Installed viaUpgrade with
Install script or standalone binaryfrg update
.deb (apt)sudo apt update && sudo apt install --only-upgrade frg
.rpm (dnf)sudo dnf upgrade frg

Permissions

If the install directory (by default /usr/local/bin) is not writable by your user, run sudo frg update. Alternatively, reinstall to a directory you own with the install script's --install-dir option:

bash
curl -fsSL https://github.com/telerik/forge/releases/latest/download/install.sh | sh -s -- --install-dir ~/.local/bin

--install-dir is an option of install.sh, not of frg update.

Exit codes

CodeMeaning
0The update succeeded, or the installed version is already current.
Non-zeroThe update failed; the previous installation is unchanged.

Troubleshooting

error: unrecognized subcommand 'update'

Cause: The frg binary on your PATH is older than the installed release.

Solution:

  1. Check your version with frg --version.
  2. Upgrade with the installer or your package manager. See Installation: Upgrading.

Permission denied

Cause: The directory that contains frg is not writable by the current user.

Solution:

  1. Run sudo frg update, or
  2. Reinstall to a user-writable directory with install.sh --install-dir (see Permissions).

The update fails verification or download

Cause: The download was incomplete or corrupted, or GitHub rate-limited the request.

Solution:

  1. Wait a few minutes and run frg update again.
  2. If it keeps failing, download the release from GitHub Releases, verify it with gpg --verify <artifact>.asc <artifact>, and install it manually.

See Also