clipbuzz is a simple program that uses the X Fixes Extension
to wait until a new clipboard or primary selection is available and exit.
It was translated from clipnotify in C to Zig, and is intended for use
within a clipboard manager like threa to avoid polling for selections.
zig build install --prefix $PREFIX
$PREFIX is usually
depending on your preference. The dependencies can usually be
found in your operating system's repository, and if you are lucky,
clipbuzz itself as well!
while clipbuzz do # something with xclip or xsel done
This is free and unencumbered software released into the public domain.