Age | Commit message (Collapse) | Author |
|
Co-authored-by: drkhsh <me@drkhsh.at>
Signed-off-by: drkhsh <me@drkhsh.at>
|
|
Generically reads an arbitrary file natively.
Saves a few layers of execution in comparison to using `run_command`
with an argument like `cat ./file`.
|
|
Just use the format strings dude. :)
|
|
function prototype with unspecified argument is obsolete since c99.
additionally some of these function which don't take any argument were
being called with a `const char *` arg, which is UB.
fix both these issues by declararing ALL the components to accept a
`const char *`, and name the arg "unused" if it's meant to be ignored.
|
|
according to both the function definition and the comment in
config.def.h, keyboard_indicators() should take a format string.
|
|
|
|
|
|
Function declarations should include variable names.
For functions with different parameters on different platfroms they are
left out.
|
|
On OpenBSD the backlight percentage cannot be retrieved in a simple way.
The only two solutions we are aware of for now are:
- reading from /dev/ttyC0: which isn't possible without changing
permissions or running slstatus as root
- linking against xcb-xrandr: which is bloat and does not work in every
case appearently
This reverts commit 37724ac2c3f496f4736223d0d8e5d8fecb933590 for now.
|
|
Adding a new keymap component that will
indicate the current keyboard layout (language)
and variant if any was set. I use the
standard X11 XKB APIs to retrieve and parse
the xkb_symbols set with setxkbmap.
|
|
At the moment linux only, but will add support for OpenBSD as well.
|
|
|
|
Implementation of a battery_remaining function which returns the
remaining battery time in HH:MM format. Linux function still needs
implementation.
Move common code to load_apm_power_info
|
|
The third value from load_avg (idle) gives us almost the same
information as cpu_iowait. Plus OpenBSD does not offer an iowait value
as Linux and thus the corresponding function would not be portable.
|
|
- Battery power cannot be easily gatherable via apm(4)
- IMHO it does not represent essential information
|
|
|
|
|
|
|
|
|
|
I know formatting commits suck... And I try to avoid them.
But this commit was absolutely necessary... The coding style in this
program was not ok and not the same over the whole program.
The commit is hard to read, but this is what I changed:
- Tabs for indentation instead of spaces
- Same style over the whole program (suckless style)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
All the info function names started with "get_", which I removed to make
it easier for the user to configure the program to its needs.
Additionally I renamed some functions (e.g. get_ram_usage) to better
names, making it easier to extend the program with ram usage / total
functions.
|
|
|
|
|