From 7276c21079a7f7993d40dec3b1866edade5d6eb5 Mon Sep 17 00:00:00 2001 From: Jens Nolte <jens@nightmarestudio.de> Date: Fri, 31 Jan 2020 02:57:24 +0100 Subject: [PATCH] Add documentation --- README.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/README.md b/README.md index 5f368a8..751f5d0 100644 --- a/README.md +++ b/README.md @@ -1 +1,36 @@ # qbar + +qbar is a status command for [sway](https://swaywm.org/) and [i3](https://i3wm.org/). + +## Installation + +### Compiling from Source + +Building qbar requires [stack](https://haskellstack.org/). To build run: +``` +stack build +``` + +You can also use the scripts in the `bin`-directory (all scripts will rebuild the project if required): +``` +# Launch as swaybar status command while redirecting stderr to shell +./bin/run-sway + +# Run the binary directly (mostly used to control the bar via rpc) +./bin/run --help + +# Install the binary to ~/.local/bin +./bin/install +``` + +## Configuration + +Custom configuration is currently only possible from Haskell: +``` +myConfig :: BarIO () +myConfig = do + addBlock dateBlock + +main :: IO () +main = parseOptions >>= runQBar myConfig +``` \ No newline at end of file -- GitLab