Custom Lemonbar...

If you are looking for a specific 64-bit package and you can't find it in any of the 64-bit repos, please post a request for it here
Post Reply
User avatar
n0ctilucient
Shogun
Shogun
Posts: 438
Joined: 21 Apr 2017, 15:59
Distribution: fullmoonremix
Location: 127.0.0.1
Contact:

Custom Lemonbar...

Post#1 by n0ctilucient » 10 Jul 2018, 04:20

Lemonbuddy...
...aims to help users build beautiful and highly customizable status bars for their desktop environment, without the need of having a black belt in shell scripting.
Basically... it's a "fast and easy-to-use tool for generating status bars" for lemonbar.
see... http://slakfinder.org/show.php?pkg=1171314

This is my /usr/bin/lemonbar.sh (executable) script...

Code: Select all

#!/usr/bin/bash
# see... http://man7.org/linux/man-pages/man1/date.1.html
# see... http://blog.z3bra.org/2014/04/meeting-at-the-bar.html
# see... https://unix.stackexchange.com/questions/152299/how-to-get-memory-usedram-used-using-linux-command
# see... https://stackoverflow.com/questions/9229333/how-to-get-overall-cpu-usage-e-g-57-on-linux

# Define the status

Calendar() {
        DATETIME=$(date "+%D")

        echo -n "$DATETIME"
}

Load() {
        TOP=$(top -b -n2 -p 1 | fgrep "Cpu(s)" | tail -1 | awk -F'id,' -v prefix="$prefix" '{ split($1, vs, ","); v=vs[length(vs)]; sub("%", "", v); printf "cpu: %s%.1f%%\n", prefix, 100 - v }')

        echo -n "$TOP"
}

Memory() {
        FREE=$(free | awk '/Mem/{printf("mem: %.2f%"), $3/$2*100}')

        echo -n "$FREE"
}

Clock() {
        DATETIME=$(date "+%I:%M %p")

        echo -n "$DATETIME"
}

# Print the status

while true; do
        echo "%{l} $(Calendar) %{c} $(Load) $(Memory) %{r} $(Clock)"
        sleep 1
done
...it places the date on the left... the time on the right
and the processor and memory usage in the center
using a white foreground on a translucent background.

Pls Note: I use PekWM. So in order to activate lemonbar... I use a line
in /etc/pekwm/start (executable) which points to /usr/bin/automate.sh
(executable) which points to lemonbar.sh (executable)

Site is @...
https://github.com/Sun24Y/lemonbuddy

Source is @...
https://github.com/Sun24Y/lemonbuddy/releases

This package has not been adopted yet by ("slackonly" or)...
https://slakfinder.org
https://slackbuilds.org
https://pkgs.org

So far... I have not been able to successfully compile this package with the following src2pkg.conf @...
Everything you wanted to know about "hardened" compile flags and src2pkg.conf (...but were afraid to ask)

Thanx... in advance to anyone that IS interested in sharing their precompiled package link.
:hmmm: I do NOT have the "right" to tell anyone what they should do...
but I reserve the "right" to tell them what they should "consider".

Post Reply