A fast terminal snippet manager. Save shell one-liners and code snippets, then fuzzy-search and paste them back without ever leaving the terminal. Everything lives in a local file — no accounts, no sync server, no telemetry.
I kept re-deriving the same ffmpeg, jq, and git incantations, or digging
through shell history hoping I'd typed one recently. snipkit is the little tool
I wanted: type three letters, get the command, paste it. That's it.
- Fuzzy search with an acronym-friendly ranker —
gcofindsgit checkout. - Two local backends: a human-readable JSON document, or SQLite when you want indexing. Switch with a flag or an environment variable.
- Clipboard integration on macOS (
pbcopy), Wayland (wl-copy), X11 (xclip/xsel), and Windows (clip). - Interactive picker that uses
fzfwhen it's available and falls back to a numbered prompt otherwise. - Shell key bindings for bash, zsh, and fish — bind a key and drop a snippet straight onto the command line.
- Import / export as plain JSON, so your snippets are yours to move around.
- Zero network. snipkit never opens a socket.
$ go install github.com/realmaxc/snipkit/cmd/snipkit@latestOr build from source:
$ git clone https://github.com/realmaxc/snipkit
$ cd snipkit
$ make build # produces ./snipkit$ echo 'git log --oneline --graph --decorate --all' | \
snipkit add -title "git graph" -lang sh -tag git
$ snipkit list
ID LANG TAGS TITLE
k3f9a1b2 sh git git graph
$ snipkit search gitgraph
ID LANG TAGS TITLE
k3f9a1b2 sh git git graph
$ snipkit copy k3f # id prefixes work too
copied k3f9a1b2 to clipboardBy default snipkit keeps a JSON store at
$XDG_DATA_HOME/snipkit/snippets.json (falling back to
~/.local/share/snipkit/snippets.json).
| Setting | Env var | Flag | Default |
|---|---|---|---|
| Store path | SNIPKIT_DB |
--db |
.../snipkit/snippets.json |
| Backend | SNIPKIT_BACKEND |
--backend |
json |
| Editor | SNIPKIT_EDITOR, VISUAL, EDITOR |
— | vi |
$ snipkit --backend sqlite --db ~/snips.db listBind Ctrl+S to the interactive picker — see
examples/shell/. For bash:
source /path/to/snipkit/examples/shell/bash-widget.shMIT © Max Collins