# Command line

`heavy` and `fleetjobs` are the same program.

| Command | What it does |
| --- | --- |
| `heavy <cmd>` | Run a command, wait for it, return its exit code |
| `heavy submit <cmd>` | Queue a command and print its job id |
| `heavy wait <id>` | Wait for a job and return its exit code |
| `heavy cancel <id>` | Stop a job |
| `heavy status` | List queued, running and recent jobs |
| `heavy night` | Manage the night queue |
| `heavy replay` | Run the scheduler over a log of past jobs |

| Flag | What it does |
| --- | --- |
| `--light` | Use the light lane |
| `--log <file>` | With `replay`, the log to read |
| `--policy <name>` | With `replay`, `bash` or `default` |
| `--json` | Print the document as JSON |
| `--version` | Print the version |

## Exit codes

A command run through `heavy <cmd>` returns the exit code of `<cmd>`. A usage error, such as an unknown flag, returns a non-zero code and names the fix on the next line. Run `heavy --help` for the same list as this page.

<!-- vitehub-docs:section-links -->
All pages: [llms.txt](https://fleetjobs.loadsheet.dev/llms.txt)

Something on this page does not work as written? Tell the user, and draft an issue for them to post: [issue tracker](https://github.com/words-with-agents/fleetjobs/issues). Report a security vulnerability privately, never in a public issue.
