stash is a small local store for pipeline output and ad hoc file snapshots.
It stores each entry as raw bytes under ~/.stash, assigns it a stable ULID,
and lets you retrieve entries by recency or ID later. Everything is flat files
and directories.
Tip
stash fits nicely in any workflow that would involve temporary files, or expensive output that needs to be processed in more than one ways.
Save output and reuse it:
curl -s https://api.example.com/data | stash
stash cat | jq .
stash cat | jq '.items[]'Keep the pipeline flowing while saving the same bytes:
curl -s https://api.example.com/data | stash tee | jq .Use with diff:
find . -type f | sort | stash -m label=before
# ... later ...
find . -type f | sort | stash -m label=after
diff -u <(stash cat @2) <(stash cat @1)File-oriented view:
stash ls
stash log
stash attr @1Clone the repo, and run make build. Copy the generated binary stash to a
location in your PATH.
Available under releases.
brew install vrypan/tap/stashFor auto-completion and other shell-specific features, check:
By default, stash stores data under ~/.stash.
You can override the stash root with STASH_DIR:
STASH_DIR=/tmp/job-a stash log
STASH_DIR=/tmp/job-a stash Makefile
STASH_DIR=/tmp/job-b stash logThis is useful when you want separate independent stashes for different jobs, projects, or CI runs.
- Usage guide: docs/usage.md
- Command/reference guide: docs/reference.md
- Example workflows: docs/examples.md
- Shell completion setup: docs/bash.md, docs/fish.md, docs/zsh.md
- Demos: demos/
- Helper scripts: scripts/README.md
Note
What is ~{@??? An ASCII art acorn.