r/coolgithubprojects • • 4d ago

Clipboard history without Win+V: just keep pressing Ctrl+V [AHK v2]

Post image

Win+V is fine, but I wanted something faster: no popup, no extra shortcut.

- Copy things as usual. The script remembers your last 7 text copies (no duplicates).

- Ctrl+V pastes normally.

- Press Ctrl+V again within 1.2 s and the pasted text is replaced by the previous copy.

Keep pressing to go further back; it loops around after the last one.

- Wait more than 1.2 s and Ctrl+V goes back to being a normal paste of your latest copy.

Under the hood it's just Ctrl+Z (undo the last paste) + swap the clipboard + Ctrl+V again.

Limitations

- Only for Windows.

- Text only (images/files are ignored).

- Relies on Ctrl+Z, so it misbehaves in apps where undo doesn't cleanly remove a paste (some terminals, games, certain web fields).

- History lives in memory only: nothing is written to disk, and it's cleared when the script exits.

Code on Github : https://github.com/Placidelinkpehoun/CallbackCrtlV

2 Upvotes

0 comments sorted by