Skip to content

Repository files navigation

Coffer: A clipboard with a long memory

A macOS menu bar clipboard manager, everything you copy, kept safe, searchable, and one shortcut away.
A single dependency-free Swift Package, builds with the swift CLI alone, no Xcode project required.

What it does

  • Watches the pasteboard and keeps a history of everything you copy (skipping entries that password managers mark as concealed).
  • Press ⌘⌥C anywhere to summon the history panel, / to pick an entry, (or double-click) to copy it back to the clipboard, Esc to dismiss. The trash button beside the search field wipes the whole history, after asking once.
  • Keeps the history newest-first, promotes re-copied items instead of duplicating them, and caps the stored count, a pure model in ClipboardHistory.swift, tests and all.

Building the app

./Scripts/bundle.sh
open build/Coffer.app

The app icon is compiled from the Icon Composer document at Assets/AppIcon.icon (generated by swift Scripts/make-assets.swift), so on macOS 26+ the system renders it live with the Liquid Glass treatment, including the dark, clear, and tinted variants.

Development

swift run             # run once
./Scripts/dev.sh      # rebuild & relaunch on source changes
./Scripts/test.sh     # unit tests (equivalent to `swift test`)

Swift Testing needs full Xcode, Command Line Tools alone won't run it.

Code structure

Sources/Coffer/
├── main.swift                   # Entry point (accessory app, no Dock icon)
├── AppDelegate.swift            # Menu bar item, hotkey + watcher wiring
├── ClipboardHistory.swift       # Pure history model: ordering, promotion, cap (tested)
├── ClipboardStore.swift         # App-side store around the model, change notifications
├── PasteboardWatcher.swift      # changeCount polling, concealed-type filtering
├── HotKeyCenter.swift           # Carbon RegisterEventHotKey wrapper (⌘⌥C)
└── HistoryPanelController.swift # The floating history palette

Roadmap

  • Search: type in the panel to filter the history.
  • Persistence: survive relaunches; app exclusions.
  • Settings: a recordable shortcut for the history panel.

License

MIT, see LICENSE. Bundled third-party software and its licenses are listed in THIRD-PARTY-NOTICES.md.

Inspired by Maccy. No code is shared.

About

A clipboard with a long memory — a macOS menu bar clipboard manager

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages