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
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
- Detects your OS and CPU, and reads the latest version from
latest.txt. - Downloads the matching archive and
checksums.txt, and verifies the SHA-256 checksum before anything is installed. A mismatch aborts. - Installs
tokmineinto a user-level directory (no admin rights needed) and adds that directory to your PATH. - Creates the
tmalias, sotmandtokmineare the same command. - Prints the next step: run
tokmine.
Open a new terminal afterwards so the updated PATH is picked up, then check it worked:
tokmine version
# or, with the alias:
tm versionOptions
| Option | Effect |
|---|---|
TOKMINE_VERSION=1.2.3 | Install a specific version instead of the latest. |
--system | Install for all users (for example into /usr/local/bin). May require sudo. |
--no-alias | Do not create the tm alias. |
--uninstall | Remove 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 --:
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 -- --systemUpgrade
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
# macOS / Linux
curl -fsSL https://tokmine.ai/install.sh | sh -s -- --uninstall
# Windows (PowerShell)
& ([scriptblock]::Create((irm https://tokmine.ai/install.ps1))) -UninstallSupported platforms
| OS | CPU | Archive |
|---|---|---|
| Linux | amd64, arm64, 386, arm | .tar.gz |
| macOS | amd64 (Intel), arm64 (Apple Silicon) | .tar.gz |
| Windows | amd64, arm64, 386 | .zip |
| FreeBSD, OpenBSD, NetBSD | amd64, 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.zipon Windows).checksums.txtandmanifest.json: SHA-256 sums and a machine-readable file list.
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.gzExtract 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_PROXYbefore running the installer. The CLI itself also honours the standard proxy variables. - Permission denied: the default install is per-user. For
--systemusesudo, or pick a directory you own withTOKMINE_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 Bypassin that window, then retry. tmclashes with another tool: reinstall with--no-aliasand keep usingtokmine.
More in Troubleshooting. Next: quickstart.