Kode has two official distribution paths:
- npm package (recommended):
@shareai-lab/kode(ships a Node.js runtime entry, and optional per-platform native binaries). - Standalone single-file binaries (optional): attached to GitHub Releases, built with
bun build --compile.
The npm package does not download binaries from GitHub during install.
The GitHub Release asset is a single executable file built with Bun, but it embeds a zipped JS bundle and unpacks it on first run.
- Default cache location:
~/.kode/bundled/kode/<version>-<sha>/<platform>-<arch>/... - If that directory is not writable, it falls back to
os.tmpdir().
The kode/kwa/kd entry wrapper (cli.js) prefers, in order:
- Native binary from npm
optionalDependencies:@shareai-lab/kode-bin-<platform>-<arch> - Node.js runtime entry:
node dist/index.js ...args
If you install with --no-optional / --omit=optional, Kode still runs via the Node.js entrypoint (you just won't have the optional native binary / bundled ripgrep).
Windows ARM64 note: if the win32-arm64 binary package is unavailable, Kode will attempt to use the win32-x64 binary (x64 emulation).
Each release publishes assets named:
kode-<platform>-<arch>(macOS/Linux)kode-<platform>-<arch>.exe(Windows)
and a checksums-sha256.txt file.
Example:
./kode-darwin-arm64 --versionYou must build on the target OS/arch (GitHub Actions does this via a matrix build).
bun install --frozen-lockfile
# Optional but recommended: include WebUI + platform ripgrep in the binary payload
bun run build
bun run scripts/ensure-ripgrep.mjs --current-only
bun run build:binaryOutput location:
dist/bin/<platform>-<arch>/kode(.exe)
To prepare the npm binary platform packages from the built artifacts:
node scripts/prepare-kode-bin-packages.mjs- Stable and prerelease tags:
.github/workflows/npm-publish.yml