CLI Reference

Huskies ships as a single huskies binary. Day to day you work through Claude, chat and the board; the command line is for setting machines up. Run huskies --help for the full list, or huskies host for the host commands.

Setting up

huskies org init

Creates your gateway: the machine that holds your org's identity, chat bot and project list. The install script runs this for you on the first machine.

huskies org init [--service-url <URL>] [PATH]

With no PATH it sets the gateway up in its default data directory, installs and starts it as a system service (huskies-org under systemd on Linux, a LaunchDaemon on macOS) and joins this machine as the org's first host. It runs locally and needs no huskies.dev account. With a PATH, it writes the gateway there and prints the command to start it yourself instead of installing a service. It is safe to re-run: an existing identity is reported, not replaced.

FlagDescription
--service-url <URL>Optional. Also link the gateway to huskies.dev (for example https://huskies.dev). Also readable from HUSKIES_SERVICE_URL.

huskies setup

Connects Claude Code to your gateway and starts Claude with a setup prompt. Claude checks what is still missing (Docker, a Claude login for the coders, your forge, a first project) and walks you through each step.

huskies setup

Run it on the gateway machine, after huskies org init. It registers the gateway's tools with Claude Code for your user, so any Claude Code session you open afterwards can use them too.

Hosts

A host is a machine that runs your projects and their coders. The gateway's own machine is the first; add more with host join.

huskies host join

sudo huskies host join ORG_NODE_URL JOIN_TOKEN [--name NAME] [--force] [--config PATH] [--identity-key PATH]

Joins this machine to the gateway at ORG_NODE_URL, using a one-time JOIN_TOKEN (ask Claude for one, or say hosts token in chat). It writes the host's configuration, then installs and starts the host service itself: a LaunchDaemon on macOS, the huskies-host systemd unit on Linux.

FlagDefaultDescription
--name NAME—Name this host is shown under.
--force—Join again when this machine has already joined a gateway.
--config PATH/etc/huskies/host.tomlWhere to write the host configuration.
--identity-key PATH/var/lib/huskies/host.keyWhere to keep the host's identity key.

huskies host run

huskies host run [--config PATH]

Runs the host agent in the foreground. This is what the host service runs; you only need it yourself when debugging.

huskies host uninstall

sudo huskies host uninstall [--purge]

Stops and removes the host service. The host's configuration and identity are left in place so it can be reinstalled; add --purge to remove them too.

Running a node by hand

The services above run these for you. They are here for debugging and for setups that do not use the packaged services.

huskies [OPTIONS] [PATH]            # serve a project
huskies --gateway [OPTIONS] [PATH]  # run a gateway (also: huskies org run)
huskies agent [OPTIONS] [PATH]      # run a headless build agent
FlagDescription
--port <PORT>Port to listen on (default: 3001).
--gatewayStart as a gateway: reads projects.toml from PATH (or the current directory).
--join-token <TOKEN>Agent mode: one-time token for registering this build agent. Also HUSKIES_JOIN_TOKEN.
--gateway-url <URL>Agent mode: the gateway to register with. Also HUSKIES_GATEWAY_URL.
-h, --helpPrint help and exit.
-V, --versionPrint the version and exit.

PATH is an existing project directory; when omitted, huskies searches parent directories for a .huskies/ folder.

Project settings

huskies config dump
huskies config set <key> <value>

Prints, or changes, a project's operational settings such as max_coders or default_qa. Both work while the node is stopped; a value of null clears an override. Run them from the project directory. Claude can change the same settings for you.

Pipeline gate commands

The binary also carries the checks huskies runs on every branch before it merges: source-map-check, jscpd-check, file-size-check, plus maintenance tools such as move-module, migrate and containerise. Huskies runs these itself; huskies --help describes each one.