| name | clipboard-history |
| description | Access persistent clipboard history from the terminal. Use when retrieving previously copied text, searching clipboard history, or restoring old clipboard content. Triggers include "clipboard history", "what did I copy", "clp", "paste old content", "clipboard search", "recover copied text". |
clipboard-history
CLI tool for persistent clipboard history with search and restore.
Quick Start
clp daemon start
clp list
clp search "function fetch"
clp get 1041 --copy
clp pick
Daemon
The daemon runs in the background and polls the clipboard every 500ms. It must be running to capture new entries.
clp daemon start
clp daemon stop
clp daemon status
Add clp daemon start to your shell profile to start automatically.
List History
clp list
clp list --limit 50
clp list --today
clp list --type url
Search
clp search "error message"
clp search "function fetch"
clp search '"exact phrase"'
Get and Restore
clp get 1041
clp get 1041 --copy
clp pick
Delete
clp delete 1041
clp delete 1041 --yes
clp clear
clp clear --yes
Statistics
clp stats
clp config
Content Types
| Type | Detection Rule |
|---|
url | Starts with http:// or https:// |
email | Matches email address pattern |
code | Has newlines + programming syntax |
text | Everything else |
Environment Variables
| Variable | Default | Description |
|---|
CLP_DB_PATH | ~/.local/share/clipboard-history/db.sqlite | Database path |
CLP_MAX_ENTRIES | 10000 | Maximum entries before pruning oldest |
CLP_POLL_MS | 500 | Daemon polling interval (milliseconds) |
CLP_NO_COLOR | 0 | Disable ANSI color (1 to disable) |
CLP_DEBUG | 0 | Enable debug logging (1 to enable) |
Exit Codes
| Code | Meaning |
|---|
| 0 | Success |
| 1 | No results / empty history |
| 2 | Daemon error |
| 3 | Runtime error |