diff options
Diffstat (limited to 'README.md')
-rw-r--r-- | README.md | 45 |
1 files changed, 31 insertions, 14 deletions
diff --git a/README.md b/README.md index f86ef96..ef1e63d 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,35 @@ -clipnotify is a simple program that, using the -[XFIXES](https://cgit.freedesktop.org/xorg/proto/fixesproto/plain/fixesproto.txt) -extension to X11, waits until a new selection is available and then exits. +# clipbuzz +`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. -It was primarily designed for [clipmenu](https://github.com/cdown/clipmenu), to -avoid polling for new selections. +## Installation +`clipbuzz` depends on [Xlib] and an [implementation of Xfixes] +and uses [Zig] build tool: -Here's how it's intended to be used: +```sh +zig build install --prefix $PREFIX +``` - while clipnotify; do - [an event happened, do something with the selection] - done +where `$PREFIX` is usually `$HOME/.local`, `/usr/local` or `/usr` +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! -clipnotify doesn't try to print anything about the contents of the selection, -it just exits when it changes. This is intentional -- X11's selection API is -verging on the insane, and there are plenty of others who have already lost -their sanity to bring us xclip/xsel/etc. Use one of those tools to complement -clipnotify. +## Usage +```sh +while clipbuzz +do # something with xclip or xsel +done +``` + +## Copying +This is free and unencumbered software released into the public domain. + +[X Fixes Extension]: https://gitlab.freedesktop.org/xorg/proto/fixesproto +[clipnotify]: https://github.com/cdown/clipnotify +[threa]: https://sr.ht/~cnx/threa +[Xlib]: https://gitlab.freedesktop.org/xorg/lib/libx11 +[implementation of Xfixes]: https://github.com/Airblader/unclutter-xfixes +[Zig]: https://ziglang.org |