summary refs log tree commit diff
path: root/README.md
diff options
context:
space:
mode:
authorNguyễn Gia Phong <mcsinyx@disroot.org>2021-06-19 15:23:47 +0700
committerNguyễn Gia Phong <mcsinyx@disroot.org>2021-06-19 15:40:32 +0700
commit7451d8fce4c50729ab3192c93422fa79c9e4fe85 (patch)
tree5a3e89989103b43aac1e3c934f4897b11f91ae2e /README.md
parenta9faca40b3929f22ad1e21c071c853af47b0b7bc (diff)
downloadclipbuzz-2.0.0.tar.gz
Translate from C to Zig 2.0.0
Diffstat (limited to 'README.md')
-rw-r--r--README.md45
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