CLI reference
The Spyke CLI is run from a terminal, inside your project folder. This page lists every command.
If you’re new to Spyke, start with the getting-started tutorial instead — it walks through the common commands in order.
Commands at a glance
Section titled “Commands at a glance”| Command | What it does |
|---|---|
spyke init | Start tracking the current folder. Run once per project. |
spyke save | Save the current state of the program as a new version. |
spyke history | List every saved version, newest first. |
spyke compare | Show what changed between versions. |
spyke restore | Bring back an earlier version. |
Run any command with --help to see its options:
spyke save --helpspyke init
Section titled “spyke init”Sets up the project history for the current folder — the running record of every version you save. Run this once, in the folder that holds your program file.
spyke initSpyke stores the history in plain Git, so your work is never locked into a proprietary format. You don’t need to know Git to use Spyke.
spyke save
Section titled “spyke save”Saves the current state of your program as a new version, with a short message describing it.
spyke save -m "Increase infeed timer preset to 5s"| Option | Description |
|---|---|
-m, --message | A plain-language description of the version. Required. |
Write messages the way you’d explain the change to a coworker — for example,
"Add jam-detection timer to infeed conveyor". Clear messages make your
history easy to read later.
spyke history
Section titled “spyke history”Lists every saved version, newest first. Each entry shows the version, who saved it, when, and the message.
spyke historyspyke compare
Section titled “spyke compare”Shows what changed between two versions, the way an engineer reads a program — the specific rung, tag, or setpoint that changed. See Semantic diffs for how this works.
With no arguments, compare shows what’s changed since your most recent saved
version:
spyke compareYou can also compare any two saved versions:
spyke compare <older> <newer>| Option | Description |
|---|---|
--json | Output the result as JSON instead of text, for use in scripts. |
spyke restore
Section titled “spyke restore”Brings back an earlier version of the program, so you can return to a state you know worked.
spyke restore <version>Use spyke history to find the version you want.