Abstrax

Self

The self command group manages the Abstrax CLI itself. It is separate from package update and package upgrade, which manage system packages through apt.

Permissions

self update requires root because it replaces the running binary, which is typically installed in a system directory such as /usr/local/bin or /usr/bin.

sudo abstrax self update

--dry-run does not require root because it only resolves the target version and reports what would happen.

self update

Update the Abstrax CLI from GitHub releases.

sudo abstrax self update [version] [flags]
Argument / flag Description
[version] Optional target version (without a leading v). Must exist on GitHub.
--allow-breaking Upgrade to the latest release even when it includes breaking (major version) changes
--plugins After the CLI update, also update every installed registry or manifest plugin

Default behaviour

When no version is given, Abstrax uses semantic versioning to choose a target:

  • It looks at all published, non-prerelease versions on GitHub.
  • It selects the newest release that shares your current major version.
  • It skips major version bumps unless you pass --allow-breaking.

For example, on version 1.0.1 with 1.1.0 and 2.0.0 available, the default target is 1.1.0.

When you pass a version explicitly, Abstrax validates that the release exists on GitHub before downloading. An explicit version is installed even if it is a major version bump.

What happens during an update

  1. The current version is read from the running binary.
  2. Published releases are fetched from the GitHub API.
  3. The target version is resolved.
  4. If no update is needed, Abstrax reports that you are up to date.
  5. Otherwise it downloads the release archive and checksums file, verifies the SHA-256 hash, extracts the binary, and replaces the running executable.
  6. If --plugins was passed, Abstrax then updates installed plugins. See Updating plugins.

Abstrax only supports linux/amd64 and linux/arm64.

Updating plugins

--plugins is optional. Without it, self update does not change installed plugins.

sudo abstrax self update --plugins
abstrax self update --plugins --dry-run

With --plugins, Abstrax updates the CLI first, then updates each installed plugin the same way as plugin update:

  • Registry and manifest plugins move to the latest compatible stable version.
  • A plugin that is already on that version is left in place.
  • Local plugins installed with --path are skipped. Update those with plugin update <name> --path ….
  • A failure for one plugin does not stop the others. If any plugin fails, the command exits with an error after the remaining plugins have been attempted. The CLI update is kept.

--dry-run lists the plugins that would change and does not install them. It does not require root.

When no plugins are installed, Abstrax reports that and exits successfully.

Updated from 1.0.1 to 1.1.0.
Updated plugin deploy from 0.3.0 to 0.4.0.
Plugin composer is already up to date (1.2.0).
WARNING: Skipped local plugin custom. Update it with plugin update --path.

--json adds a plugins object to data. It is omitted when --plugins was not passed. skipped entries use reason up_to_date or local.

"plugins": {
  "dry_run": false,
  "updated": [
    {
      "name": "deploy",
      "version": "0.4.0",
      "previous_version": "0.3.0"
    }
  ],
  "skipped": [
    {
      "name": "composer",
      "version": "1.2.0",
      "reason": "up_to_date"
    },
    {
      "name": "custom",
      "version": "0.1.0",
      "reason": "local"
    }
  ],
  "failed": []
}

If a plugin fails, the result status is error, error_code is plugin_update_failed, and data still includes the CLI update fields and the plugins object. summary is the CLI update message. message describes the plugin failure.

Examples

Update to the newest compatible release:

sudo abstrax self update

Update to a specific version:

sudo abstrax self update 1.2.0

Upgrade to the absolute latest release, including major versions:

sudo abstrax self update --allow-breaking

Update the CLI and every installed plugin:

sudo abstrax self update --plugins

Preview without making changes:

abstrax self update --dry-run

JSON output:

sudo abstrax self update --json
{
  "status": "success",
  "action": "self.update",
  "summary": "Updated from 1.0.1 to 1.1.0.",
  "data": {
    "current_version": "1.0.1",
    "target_version": "1.1.0",
    "latest_version": "2.0.0",
    "breaking_version": "2.0.0",
    "updated": true,
    "already_up_to_date": false,
    "breaking_update_available": true,
    "message": "Updated from 1.0.1 to 1.1.0.",
    "notice": "A newer major release (2.0.0) is available with breaking changes. Run `abstrax self update --allow-breaking` when you are ready to upgrade."
  }
}

When already up to date:

sudo abstrax self update
You are already on the latest compatible release (1.1.0).
WARNING: A newer major release (2.0.0) is available with breaking changes. Run `abstrax self update --allow-breaking` when you are ready to upgrade.

Errors

Common errors:

Error Cause
this command requires root privileges Run with sudo
version X.Y.Z does not exist on GitHub The requested version was not found among published releases
self-update is only supported on Linux The command was run on a non-Linux system
checksum mismatch The downloaded archive failed verification; the update was aborted
unsupported architecture The server architecture is not amd64 or arm64
failed to update plugin … A registry or manifest plugin could not be updated. The CLI update is kept, and the other plugins were still attempted
  • Updating - full update guide including manual archive steps.
  • Installation - first-time installation.