Docs

Install

The CLI is a single static binary. One command installs it, puts it on your PATH and adds a short alias, tm.

One-line install

bash
curl -fsSL https://tokmine.ai/install.sh | sh

Both scripts are served from https://cdn.tokmine.ai/cli/downloads/ (the URLs on this site redirect there), so you can read them before running them.

What the installer does

  1. Detects your OS and CPU, and reads the latest version from latest.txt.
  2. Downloads the matching archive and checksums.txt, and verifies the SHA-256 checksum before anything is installed. A mismatch aborts.
  3. Installs tokmine into a user-level directory (no admin rights needed) and adds that directory to your PATH.
  4. Creates the tm alias, so tm and tokmine are the same command.
  5. Prints the next step: run tokmine.

Open a new terminal afterwards so the updated PATH is picked up, then check it worked:

bash
tokmine version
# or, with the alias:
tm version

Options

OptionEffect
TOKMINE_VERSION=1.2.3Install a specific version instead of the latest.
--systemInstall for all users (for example into /usr/local/bin). May require sudo.
--no-aliasDo not create the tm alias.
--uninstallRemove the binary, the alias and the PATH entry the installer added. Your config in ~/.config/tokmine is left alone.

Pass flags through the pipe with sh -s --:

bash
curl -fsSL https://tokmine.ai/install.sh | TOKMINE_VERSION=1.2.3 sh -s -- --no-alias
curl -fsSL https://tokmine.ai/install.sh | sh -s -- --system

Upgrade

Re-run the install command. It replaces the binary in place and keeps your login and config. A built-in tokmine update is not available yet.

Uninstall

bash
# macOS / Linux
curl -fsSL https://tokmine.ai/install.sh | sh -s -- --uninstall

# Windows (PowerShell)
& ([scriptblock]::Create((irm https://tokmine.ai/install.ps1))) -Uninstall

Supported platforms

OSCPUArchive
Linuxamd64, arm64, 386, arm.tar.gz
macOSamd64 (Intel), arm64 (Apple Silicon).tar.gz
Windowsamd64, arm64, 386.zip
FreeBSD, OpenBSD, NetBSDamd64, arm64.tar.gz

The download page lists exactly what the latest release contains.

Manual download

Prefer to do it by hand? Everything lives under https://cdn.tokmine.ai/cli/downloads/:

  • latest.txt: the latest version number.
  • <version>/tokmine_<version>_<os>_<arch>.tar.gz (or .zip on Windows).
  • checksums.txt and manifest.json: SHA-256 sums and a machine-readable file list.
bash
curl -fsSL https://cdn.tokmine.ai/cli/downloads/latest.txt
curl -fsSLO https://cdn.tokmine.ai/cli/downloads/1.2.3/tokmine_1.2.3_linux_amd64.tar.gz
curl -fsSL https://cdn.tokmine.ai/cli/downloads/checksums.txt | grep linux_amd64
sha256sum tokmine_1.2.3_linux_amd64.tar.gz

Extract the archive and move tokmine to a directory on your PATH.

Troubleshooting

  • tokmine: command not found: open a new terminal (PATH is only read at start). If it still fails, add the install directory printed by the installer to your PATH.
  • Behind a proxy: set HTTPS_PROXY before running the installer. The CLI itself also honours the standard proxy variables.
  • Permission denied: the default install is per-user. For --system use sudo, or pick a directory you own with TOKMINE_INSTALL_DIR.
  • Checksum mismatch: the download was corrupted or intercepted. Retry, and if it persists tell us. Nothing is installed in that case.
  • PowerShell blocks the script: run Set-ExecutionPolicy -Scope Process Bypass in that window, then retry.
  • tm clashes with another tool: reinstall with --no-alias and keep using tokmine.

More in Troubleshooting. Next: quickstart.