Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Installation

You install Argon by installing one binary: oxup. From there, oxup fetches the rest of the toolchain and keeps it up to date, the way rustup does for Rust.

What gets installed

A complete Argon toolchain bundles six things:

  • oxc — the compiler.
  • ox — the project manager: ox check, ox build, ox test, ox query, ox mutate, ox diagram, and the package commands.
  • ox-lsp — the language server, used by the editor extension.
  • std — the standard library bundle.
  • tree-sitter-argon — the grammar, compiled to a dynamic library.
  • shell-completion scripts.

A single oxup binary does the work of oxup, ox, oxc, and ox-lsp by inspecting argv[0]. The proxy binaries in ~/.argon/bin/ are symlinks back to the same oxup binary, so installing a new toolchain version is a single atomic flip of the active symlinks.

Install via Homebrew

$ brew tap sharpe-dev/tap
$ brew install argon
$ oxup init
$ oxup install stable

Four commands, in order:

  • brew tap sharpe-dev/tap — register the Argon Homebrew tap.
  • brew install argon — install the toolchain.
  • oxup init — first-run setup. Provisions ~/.argon/{bin,toolchains,extensions} and adds ~/.argon/bin to your shell rc inside a guard block.
  • oxup install stable — download the latest signed toolchain and make it the default.

The shell-rc edit is bounded — it lives between two clearly-marked comment lines that oxup controls. Running oxup uninstall later cleanly removes the edit along with everything else oxup manages.

Note: the tap is private to sharpe-dev while Argon is in pre-public-release. brew tap will prompt for GitHub authentication; oxup auth login configures the token oxup itself uses to fetch toolchain release assets.

Verifying the install

Open a fresh shell and check the four commands report a version:

$ oxup --version
$ ox --version
$ oxc --version
$ ox-lsp --version

If any of them fail, run oxup doctor. It checks that ~/.argon/ exists and is writable, that the proxy symlinks resolve, that the active toolchain manifest is intact, and that the shell-integration block is present in your rc-file.

$ oxup doctor

oxup doctor --json prints the same diagnostic in machine-readable form; oxup doctor --fix applies auto-fixable repairs.

Editor extension (VS Code / Cursor)

The editor experience is the canonical UX for Argon. Install the extension via oxup, which reads the bundled VSIX from the active toolchain and hands it to your editor’s CLI:

$ oxup extension install

Pass --editor vscode or --editor cursor to override auto-detection. oxup extension status reports the installed extension version. oxup extension uninstall removes it (with --editor all to uninstall from every detected editor at once). For dev-cut toolchains that ship no release asset, oxup extension install --path ./argon-dev.vsix installs a locally-built VSIX while still recording the install in oxup’s state.

The extension brings: LSP-driven hover, semantic highlighting, inlay hints, palette commands for ox query / ox mutate / ox diagram / ox test, an output channel for compiler messages, and the InfoView panel. Use it. The book’s later chapters reference InfoView output directly.

Updating

$ oxup update

Updates the default toolchain to the latest channel build. Pass a specific version to update just that one: oxup update 0.4.0.

To roll back to a previously-installed toolchain: oxup default <version>. To list installed toolchains: oxup toolchain list. To remove a specific version: oxup toolchain remove <version>. To garbage-collect older toolchains while keeping the active one: oxup toolchain gc [--keep N] [--keep-active] [--dry-run]. To check authentication status: oxup auth status. To update or uninstall oxup itself: oxup self update / oxup self uninstall. To uninstall everything oxup manages (including the shell-rc edit): oxup uninstall.

Channels

oxup resolves toolchains through four channel forms (oxup/src/channel.rs::Channel):

  • stable — the newest non-prerelease tag.
  • nightly — the newest nightly-YYYY-MM-DD tag.
  • nightly-YYYY-MM-DD — a specific dated nightly.
  • An exact version string — 0.4.0, 0.4.0-rc.1, etc.

Pin a channel:

$ oxup install nightly
$ oxup default nightly

Or pin to an exact version:

$ oxup install 0.4.0
$ oxup default 0.4.0

What’s next

Open a terminal in a fresh directory. The next chapter writes the smallest meaningful Argon program and runs it through the compiler.