Skip to content

buiilding/global-key-copy-daemon

Repository files navigation

Global Key Copy Daemon

Standalone Ubuntu daemon that tracks recently typed keys, clears after idle timeout, and copies tracked text when you press a hotkey.

Default behavior:

  • Hotkey: Ctrl+Shift+G
  • Idle clear timeout: 3 seconds
  • Buffer: rolling character history (4096 max)

Prebuilt Downloads

Prebuilt binaries and installers are published on each tagged release:

  • .exe for Windows (keycopy-daemon-windows-x64.exe)
  • .dmg for macOS Apple Silicon (keycopy-daemon-macos-arm64.dmg)
  • .deb for Ubuntu/Debian amd64 (keycopy-daemon_<version>_amd64.deb)

Release page:

  • https://github.com/buiilding/global-key-copy-daemon/releases/latest

Important limitations

  • This captures key events, not each app's final text state.
  • It can capture sensitive input (passwords, API keys, private text).
  • On Wayland sessions, global key capture may be blocked by compositor/security policy.

Requirements

  • Python 3.10+
  • One clipboard tool installed:
    • Wayland: wl-copy from wl-clipboard
    • X11: xclip or xsel

Install clipboard utilities if needed:

sudo apt update
sudo apt install -y wl-clipboard xclip

Quick run

cd /mnt/E/Assistants/TaskOrca_workspace/global-key-copy-daemon
chmod +x start.sh
./start.sh

Then:

  1. Type some text in any app.
  2. Press Ctrl+Shift+G.
  3. Paste somewhere else to confirm copied text.

Stop with Ctrl+C in the daemon terminal.

Windows and macOS Notes

  • Windows: run the .exe from release assets.
  • macOS: open the .dmg, copy the binary out, then run it from Terminal.
  • Linux: install the .deb or run from source.

Install as user service (auto-start)

cd /mnt/E/Assistants/TaskOrca_workspace/global-key-copy-daemon
chmod +x install-user-service.sh
./install-user-service.sh

Useful commands:

systemctl --user restart keycopy-daemon.service
systemctl --user stop keycopy-daemon.service
systemctl --user disable keycopy-daemon.service
journalctl --user -u keycopy-daemon.service -f

Configuration

Environment variables (or CLI flags) control behavior:

  • KEYCOPY_HOTKEY (default: <ctrl>+<shift>+g)
  • KEYCOPY_IDLE_SECONDS (default: 3)
  • KEYCOPY_MAX_BUFFER (default: 4096)
  • KEYCOPY_POLL_SECONDS (default: 0.1)

Example:

KEYCOPY_IDLE_SECONDS=5 KEYCOPY_MAX_BUFFER=10000 ./start.sh

Troubleshooting

  • If hotkeys do nothing on Wayland, try logging into an X11 session and run again.
  • If copy fails, ensure one of these exists in PATH: wl-copy, xclip, or xsel.
  • To see logs while running manually, do not pass --quiet.

Security warning

This is effectively a key history tracker. Run only on systems you control and trust.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors