Install
Requirements
Section titled “Requirements”- Node 22.23.4+, 24.22.1+, or 26.12.1+ on a supported line or Bun 1.4.4+: either runtime works
- A POSIX shell (Linux, macOS, or WSL)
Choose Node 24.22.1+ for a new installation. Source development, dashboard
and docs tooling use that floor; the repository .nvmrc selects 24.22.1.
The published CLI still accepts patched Node 22. Its upstream support ends
April 30, 2027, so move existing Node 22 installations to Node 24 before then.
Removing Node 22 from the npm engine range will ship as a breaking minor release
with migration notes.
The published npm package ships a prebuilt dist/, so it runs on plain Node out of the box, no Bun required. Installing Bun is optional but recommended for developing Harnery: Bun runs the TypeScript source directly (zero build step), so edits are live. The package’s exports resolve to TS source under Bun and to the built dist/ everywhere else, so the two stay in lockstep.
Install
Section titled “Install”One line, no clone needed:
curl -fsSL https://harnery.com/install.sh | bashIt installs the harn CLI globally with a package manager you already have (npm preferred for a predictable global bin, Bun otherwise), checks that bin dir is on your PATH, verifies harn --version, and points you at harn init. It’s non-interactive and idempotent, so it’s safe to pipe and safe to re-run.
Prefer to drive your package manager yourself? Same result:
npm install -g harnerybun add -g harnerynpm install harnery # then run it with: npx harn …Pass flags to the one-liner through bash -s --:
curl -fsSL https://harnery.com/install.sh | bash -s -- --method bun --version 0.3.2--version (or HARNERY_VERSION) pins a version, --method npm|bun forces a package manager, and --install-runtime installs Bun when neither Bun nor Node is present (without it, the installer prints how to get a runtime and exits). It’s served straight from the docs site, so you can read it before running: harnery.com/install.sh.
What npm gives you vs a git clone
Section titled “What npm gives you vs a git clone”npm install harnery (what the one-liner runs) ships the CLI + coord engine (bin, dist, src, schemas): everything you need to wire hooks with harn init and run the coord layer. It does not include the web/ dashboard or this docs/ site; those are heavy app/build trees that live in the git repo only.
To run the dashboard (harn web up) or hack on Harnery itself, clone the repo (next section).
From a git clone (contributing or the dashboard)
Section titled “From a git clone (contributing or the dashboard)”Cloned the repo? One script turns it into a harnery-ready checkout: it installs deps, builds the Node dist/ (skipped when Bun is present), runs harn init to wire your project, and links the bins onto your PATH:
./scripts/setup.shRun it from the repo root. It auto-detects the project to wire (git toplevel of the CWD, else Harnery’s parent directory), and it’s idempotent. Flags: --project-root <dir>, --link-dir <dir> (default ~/.local/bin), --no-link, --adapter <id>. Reverse it with the mirror, ./scripts/teardown.sh (see Uninstall).
First-run check
Section titled “First-run check”harn doctorThis verifies the runtime + dependencies Harnery expects (Node version, optional Python, optional restic for backup, etc.). It exits 0 if everything’s wired and prints OS-specific install instructions for anything missing.
Bootstrap a project
Section titled “Bootstrap a project”harn initRun once per adapter to create the .harnery/ coord root and wire that adapter’s hooks. Pass --adapter claude-code (default), cursor, codex, or opencode; run it once per adapter when a project uses several. It is idempotent and preserves non-Harnery hooks. OpenCode has no hook file, so --adapter opencode installs a Harnery plugin under .opencode/plugins/harnery/ instead. See harn init for --dry-run and details.
Uninstall
Section titled “Uninstall”Two layers, mirroring install. Unwire a project with harn deinit (on a terminal it asks before deleting .harnery/; keeps it by default). Remove the CLI with the hosted one-liner:
harn deinit # unwire a project (keeps .harnery/)curl -fsSL https://harnery.com/uninstall.sh | bash # remove the CLI itself./scripts/teardown.sh # mirror of setup.sh; also offers to remove state + the cloneFrom a clone, ./scripts/teardown.sh runs harn deinit, removes the PATH symlinks, and (on a terminal) asks whether to also delete this project’s .harnery/ history and the clone itself (both default to no). Pre-answer for unattended runs with --purge-state and --remove-clone; it also takes --link-dir, --keep-links, --project-root, --adapter, and --dry-run. See harn deinit for the surgical, hook-preserving details.
Next steps
Section titled “Next steps”- First run: quick tour of the most common commands
- Configuration: settings file format + precedence rules