Skip to content

v2.0.0 · Go · one binary · SQLite

Stop retyping
commands.

CWM is a single-binary Go CLI that saves your shell commands under short names, records history per folder and syncs across PCs. No runtime, no daemon.

Platforms
Win · Linux · Mac
Storage
~/.cwm/cwm.db
Cloud
None
~/projects
$ cwm save hello "echo Hello World" -t util -d "Greets user"
Saved [util] hello = echo Hello World (Greets user)
$ 

What it does

Command vault

Save any command or script under a short name. Tag it, describe it, run it with -x.

$ cwm save gs "git status -sb"

History that knows folders

An optional shell hook records each command with the folder it ran in. Secrets are skipped.

$ cwm watch start

Tidy duplicates

Remove duplicate lines from your history file. Multi-line commands stay whole. A backup is written first.

$ cwm tidy history

Two-way sync

Point two PCs at one folder. CWM merges both ways, and deletes stick.

$ cwm config -c D:/shared/cwm

Undo for deletes

Deleted commands go to a trash buffer of 100. Restore one by name.

$ cwm clear -r gs

Start in three steps

  1. 1

    Install and check

    One file. Unzip it, put it on your PATH, and check that it runs.

    $ cwm hello
    Install guide →
  2. 2

    Turn on shell integration

    Adds one block to your profile so saved commands run in your current shell.

    $ cwm setup
  3. 3

    Save something you retype

    Give a long command a short name. Run it with -x.

    $ cwm save gs "git status -sb" && cwm get gs -x