Back

snipit

snipit is a fast, local-first CLI snippet manager written in Go. Store, tag, and retrieve code snippets straight from your terminal.

Go CLI Local‑first Cross‑platform
Timeline
2024 → ongoing
Stack
Go, Cobra, FS/BoltDB

Install

With Go:

go install github.com/luke-mcmahon/snipit@latest

From source:

git clone https://github.com/luke-mcmahon/snipit
cd snipit
make build
./bin/snipit --help

Usage

Add, tag, and retrieve snippets:

# add a snippet
snipit add --title "curl json" --tags http api -- 'curl -s https://api.example.com | jq .'

# list snippets by tag
snipit list --tag api

# copy snippet to clipboard
snipit get "curl json" --copy

Features

  • Blazing-fast fuzzy search with smart ranking
  • Local-first, human-readable storage (plaintext + optional BoltDB index)
  • Tags, metadata, and clipboard integration
  • Shell-agnostic output, works with zsh/bash/fish on macOS/Linux

Architecture

  • Cobra-based CLI with modular subcommands
  • Pluggable storage layer (filesystem / BoltDB)
  • Simple, portable data model for easy backups