A smart, cross-platform command clipboard manager for the terminal. Built by M5 Dev — GPL-3.0
history is short. grep is tedious. pet is Go-only.
cmdclip is Python, works on Linux / macOS / Windows, and has AI built in.
pip install cmdclip# Save a command
cmdclip add "docker ps -a --format '{{.Names}}'" --tags docker,ops --note "list container names"
# List all
cmdclip list
# Search
cmdclip search docker
# Run by ID
cmdclip run a3f9
# Dry-run with AI explanation
cmdclip run a3f9 --dry-run
# AI explain any saved command
cmdclip explain a3f9
# Import from shell history (smart — picks commands used 5+ times)
cmdclip history
# Export / import
cmdclip export --output backup.json
cmdclip import backup.json --safe
# Share as a snippet (copies to clipboard)
cmdclip share a3f9
# Usage stats
cmdclip stats# Save your Groq API key once
cmdclip config set-key gsk_xxxxxxxxxxxx
# Now add / explain / dry-run all use AI automaticallyGet a free key at console.groq.com.
Use {variable} or {variable=default} syntax:
cmdclip add "ssh {user}@{host} -p {port=22}" --name ssh-connect
cmdclip run <id>
# Fill in: user? host? port [22]?Import with --safe to automatically quarantine dangerous commands
(rm -rf, sudo rm, DROP TABLE, etc.) into a separate file.
cmdclip import backup.json --safe| OS | Data directory |
|---|---|
| Linux / macOS | ~/.cmdclip/ |
| Windows | %LOCALAPPDATA%\cmdclip\ |
GNU General Public License v3.0 — see LICENSE
© M5 Dev