A3S Docs
A3S Updater

A3S Updater

Self-update library for A3S CLI binaries via GitHub Releases.

A3S Updater

a3s-updater is a small library used by A3S command-line tools to check GitHub Releases, download the matching platform archive, extract the target binary, and replace the currently running binary.

The current crate version is a3s-updater 0.2.0.

Capability Map

AreaCurrent capability
Release lookupFetches the latest GitHub release for a configured owner/repository through the GitHub Releases API.
VersioningParses semver tags with an optional v prefix and compares against the current binary version.
Platform matchNormalizes supported targets to darwin or linux and arm64 or x86_64.
Asset namingLooks for archives named <binary>-<version>-<os>-<arch>.tar.gz.
Archive handlingDownloads .tar.gz, extracts only regular files into a temporary directory, and selects the requested binary by file name.
InstallationRenames the current executable to a backup, copies the new binary into place, sets Unix executable permissions, and restores on copy failure.

Start Here

  • API Flow explains UpdateConfig, run_update, release lookup, semver comparison, and the manual fallback message.
  • Release Assets documents platform detection, expected asset names, download, and archive extraction.
  • Installation Safety covers executable replacement, backup/restore behavior, permissions, and boundaries.

Boundary

The library currently targets CLI-style binary replacement and GitHub Release assets. It is not a package manager, and unsupported operating systems or architectures are reported as unsupported rather than guessed.

On this page