Skip to main content

Stashpad

Stashpad is a personal developer reference manager (stash on the command line).

Save URLs, shell commands, code snippets, and notes. Tag them, search, export, and browse from the terminal.

Full reference: docs/

How it works

Stashpad is a local, searchable cheat sheet for developers. You save things you look up repeatedly — shell commands, snippets, URLs, notes — and find them again from the terminal.

Data storage

Everything lives in a single JSON file:

~/.config/stash/vault.json    # default location

Override with STASH_DATA_DIR, --config-dir, or a path passed to stash init. The file contains:

  • Entries — title, content, optional URL, tags, priority, kind, pinned flag, timestamps, UUID
  • Tags — a registry of tag names used in the vault

Example scripts use examples/.demo-vault/ so they never touch your real vault.

Typical workflow

stash init --name my-vault                         # create vault once
stash entry add "Docker prune" "docker ..." --tag devops
stash add "Quick note" "echo hello"              # top-level alias
git log -5 | stash add "Recent commits" -      # pipe into vault
stash pins                                       # pinned favorites
stash pick deploy --copy                         # interactive picker
stash browse                                     # split-pane TUI (poetry install -E tui)
stash search "prune"                             # fuzzy ranked search
stash entry copy <id> --first-line               # copy command to clipboard
stash entry run <id>                             # run with confirmation
stash export json ./backup.json                  # backup
stash import --from-file ./backup.json           # restore

Useful global flags: --json (scripting), --verbose, --config-dir (alternate vault).

Validation with Pydantic

Input is validated before it hits disk:

Schema Used for
EntryCreate New entries (title, URL, tags normalized)
EntryUpdate Partial edits
EntryFilter List/search filters
ImportPayload JSON import files

Invalid URLs, empty titles, or malformed import files fail early with clear errors.

Architecture

CLI commands  ──►  storage.py  ──►  vault.json
                        ▲
                        │
                  models / schemas (Pydantic)

Quick start

pip install stashpad
# or: pipx install stashpad

stash init --name my-vault

stash entry add "Docker prune" "docker system prune -af" \
  --tag devops --tag docker --url https://docs.docker.com

stash entry list --tag devops
stash search "prune"
stash --json entry list

From source:

git clone https://github.com/Vicba/stash-cli.git
cd stash-cli
poetry install
poetry install -E tui   # optional: split-pane browse UI
poetry install -E mcp   # optional: MCP server for Cursor / Claude Desktop
poetry run stash init --name my-vault

CLI commands

Command Description
stash init Initialize vault (prompts, env vars)
stash add Quick-capture alias for stash entry add (stdin, clipboard)
stash entry add/list/show/edit/remove/copy/run/pin/unpin CRUD with UUID, enums, filters, aliases (ls, rm)
stash pins List pinned favorites
stash pick Interactive fzf-style picker (--copy, --run, --open)
stash browse Split-pane TUI browser (poetry install -E tui)
stash search Fuzzy ranked search (--exact to disable)
stash mcp serve MCP server for AI assistants (poetry install -E mcp, Python 3.10+)
stash tags list/add/remove Nested subcommands
stash export json/markdown Export with Path types and progress bars
stash import Import from JSON files
stash open Open entry URL in browser
stash config show/set/path Configuration management

Global flags: --verbose, --json, --config-dir, --version

Run poetry run stash --help for full usage.

Examples

Runnable walkthroughs and sample data live in examples/:

./examples/scripts/01-getting-started.sh
./examples/scripts/04-import-export.sh

Development

poetry run poe test      # run tests
poetry run poe lint      # lint
poetry run poe dev       # dev runner

Project structure

src/stashpad/
  cli.py              # root app + global callback
  context.py          # shared AppContext
  models.py           # Entry, Vault, enums
  storage.py          # JSON persistence (~/.config/stash/)
  commands/           # one module per command group
  mcp/                # MCP service + FastMCP server
docs/                 # Reference documentation
tests/                # CLI tests

License

MIT

Metadata

Release files for stashpad 0.7.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for stashpad 0.7.0
File Size Uploaded Provenance Actions
stashpad-0.7.0.tar.gz 49.9 kB Without provenance Details for stashpad-0.7.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for stashpad 0.7.0
File Interpreter ABI Platform Actions
stashpad-0.7.0-py3-none-any.whl Python 3 none any Details for stashpad-0.7.0-py3-none-any.whl

Total release size: 116.6 kB

Release files / stashpad-0.7.0.tar.gz

Download URL stashpad-0.7.0.tar.gz
Size 49.9 kB
Tags Source
SHA-256 checksum
How to use checksums
096de16c2e370ba329c12274ba6d01a81d1e050d2e3418787a9881b3edd342c9
BLAKE2b-256 checksum
How to use checksums
38585d3c46c79fc841ae2476546f9b9c18329c5ebcac65acd7d44a7ba52fd123
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.1 CPython/3.12.13 Linux/6.17.0-1018-azure

Release files / stashpad-0.7.0-py3-none-any.whl

Download URL stashpad-0.7.0-py3-none-any.whl
Size 66.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4522fc34a267dc194f6643a2fbb08eafbb8cad12fe2f1bb5399e5dc32935dc90
BLAKE2b-256 checksum
How to use checksums
523d6e579e6058d707a81d767008ac6f4dd0b5d152c74923eca3e406228388fc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.4.1 CPython/3.12.13 Linux/6.17.0-1018-azure

Security for stashpad 0.7.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page