slstatus

Unnamed repository; edit this file 'description' to name the repository.
git clone https://git.beauhilton.com/slstatus.git
Log | Files | Refs | README | LICENSE

commit dd0f0cd30e6055201cc979497facc60dc60af215
parent 0fe8e5a961a32e56412a06b4a31a6ba543fd2dfb
Author: Aaron Marcher <info@nulltime.net>
Date:   Sun, 18 Sep 2016 17:51:25 +0200

README.md reloaded

Diffstat:
MCONTRIBUTING.md | 2++
MREADME.md | 35+++++++++++++++++++++--------------
2 files changed, 23 insertions(+), 14 deletions(-)

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md @@ -2,3 +2,5 @@ Contributing ============ If you want to contribute, please use [the suckless coding style](http://suckless.org/coding_style). + +Feel free to add yourself to [CONTRIBUTORS.md](CONTRIBUTORS.md) afterwards if you want. diff --git a/README.md b/README.md @@ -1,10 +1,10 @@ ![slstatus](slstatus.png) -**slstatus** is a suckless and lightweight status monitor for window managers that use WM_NAME as statusbar (e.g. DWM). It is written in pure C without any system calls and only reads from files most of the time. It is meant to be a better alternative to Bash scripts (inefficient) and Conky (bloated for this use). +**slstatus** is a suckless and lightweight status monitor for window managers that use WM_NAME as statusbar (e.g. DWM) or any other status bars if they support reading/piping from slstatus. It is written in pure C without any extern programs being executed and only reads from files most of the time. slstatus is meant to be a better alternative to Bash scripts (inefficient) and Conky (bloated and written in C++). -If you write a bash script that shows system information in WM_NAME, it executes a huge amount of external commands (top, free etc.) every few seconds. This results in high system resource usage. slstatus solves this problem by only using C libraries and/or reading from files in sysfs/procfs. +If you write a bash script that shows system information in WM_NAME (or any other status bar), it executes a huge amount of external commands (top, free etc.) every few seconds. This results in high system resource usage. slstatus solves this problem by only using C libraries and/or reading from files in sysfs/procfs most of the time. -Looking at the LOC (lines of code) of the [Conky project](https://github.com/brndnmtthws/conky), very interesting: *28.346 lines C++, 219 lines Python and 110 lines Lua*. slstatus currently has about **800 lines of clean documented C code** and even includes additional possibilities as it can be customized and extended very easily. Configure it by customizing the config.h (C header file) which is secure and fast as no config files are parsed at runtime. +Looking at the LOC (lines of code) of the [Conky project](https://github.com/brndnmtthws/conky), it is very interesting: *28346 lines C++, 219 lines Python and 110 lines Lua*. slstatus currently has about **800 lines of clean documented C code** and even includes additional possibilities as it can be customized and extended very easily. Configuring it by customizing the config.h (C header) file is very secure and fast as no config files are parsed at runtime. The following information is included: @@ -14,40 +14,47 @@ The following information is included: - Date and time - Disk[s] status (free storage, percentage, total storage and used storage) - Available entropy -- username/gid/uid +- Username/GID/UID - Hostname - IP addresses -- Load average +- Load averages - Memory status (free memory, percentage, total memory and used memory) - Temperature - Uptime -- Volume percentage + mute status (alsa) -- WiFi signal percentage and essid +- Volume percentage (ALSA) +- WiFi signal percentage and ESSID -Multiple entries per function are supported and everything can be reordered and customized via the C header file config.h (similar to DWM). +Multiple entries per function (e.g. multiple batteries) are supported and everything can be reordered and customized via a C header file (similar to other suckless programs). ## Usage ### Installation -Before you continue, please be sure that a C compiler (preferrably gcc), GNU make and `alsa-lib` (for volume percentage) are installed. Then copy config.def.h to config.h and customize it to fit your needs. Recompile and install it after modifications: +Be sure you satisfy the dependencies: X11 and optionally ALSA (for volume percentage, I will *not* support PulseAudio). +Also you should have basic development tools like a C compiler and GNU make installed. +Then copy config.def.h to config.h and customize it to your needs. +(Re)Compile (and install) it (after modifications): $ make clean all # make install ### Starting -Write the following code to your ~/.xinitrc (or any other initialization script): +If you use DWM or any other window manager that uses WM_NAME, write the following code to ~/.xinitrc (or any other initialization script) to start slstatus automatically: - slstatus & + slstatus -d + +If you use any other status bar or window manager you will have to figure it out yourself. Something like this could fit your requirements: + + slstatus -o | other_status_bar & ## Contributing -In [TODO.md](TODO.md) there is a list of things that have to be done. +Hunt FIXME's in the code or do WTF you want! If it is useful, I will merge. -People who contributed are listed in [CONTRIBUTORS.md](CONTRIBUTORS.md). +People who contributed are listed in [CONTRIBUTORS.md](CONTRIBUTORS.md). Please add yourself to this list afterwards. -For detailed information about coding style and restrictions see [CONTRIBUTING.md](CONTRIBUTING.md) +For detailed information about coding style and restrictions see [CONTRIBUTING.md](CONTRIBUTING.md). ## License