mirror of
https://github.com/eRgo35/dots.git
synced 2025-12-16 15:36:11 +01:00
Rofi and bar customization
This commit is contained in:
@@ -21,8 +21,8 @@ darkblue=#83bae8
|
||||
cpu() {
|
||||
cpu_val=$(grep -o "^[^ ]*" /proc/loadavg)
|
||||
|
||||
printf "^c$black^ ^b$green^ CPU"
|
||||
printf "^c$white^ ^b$grey^ $cpu_val"
|
||||
printf "^c$black^ ^b$green^ "
|
||||
printf "^c$black^ ^b$green^$cpu_val"
|
||||
}
|
||||
|
||||
pkg_updates() {
|
||||
@@ -31,9 +31,9 @@ pkg_updates() {
|
||||
# updates=$(aptitude search '~U' | wc -l) # apt (ubuntu,debian etc)
|
||||
|
||||
if [ -z "$updates" ]; then
|
||||
printf " ^c$green^ Fully Updated"
|
||||
printf " ^c$blue^ Fully Updated"
|
||||
else
|
||||
printf " ^c$green^ $updates"" updates"
|
||||
printf " ^c$blue^ $updates"" updates"
|
||||
fi
|
||||
}
|
||||
|
||||
@@ -48,8 +48,8 @@ brightness() {
|
||||
}
|
||||
|
||||
mem() {
|
||||
printf "^c$blue^^b$black^ "
|
||||
printf "^c$blue^ $(free -h | awk '/^Mem/ { print $3 }' | sed s/i//g)"
|
||||
printf "^c$black^^b$red^ "
|
||||
printf "^c$black^ $(free -h | awk '/^Mem/ { print $3 }' | sed s/i//g)"
|
||||
}
|
||||
|
||||
wlan() {
|
||||
@@ -60,8 +60,8 @@ wlan() {
|
||||
}
|
||||
|
||||
clock() {
|
||||
printf "^c$black^ ^b$darkblue^ "
|
||||
printf "^c$black^^b$blue^ $(date '+%H:%M') "
|
||||
printf "^c$black^ ^b$blue^ "
|
||||
printf "^c$black^^b$blue^ $(date '+%r') "
|
||||
}
|
||||
|
||||
while true; do
|
||||
@@ -70,5 +70,5 @@ while true; do
|
||||
interval=$((interval + 1))
|
||||
|
||||
# sleep 1 && xsetroot -name "$updates $(battery) $(brightness) $(cpu) $(mem) $(wlan) $(clock)"
|
||||
sleep 1 && xsetroot -name "$updates $(cpu) $(mem) $(clock)"
|
||||
sleep 1 && xsetroot -name "$(cpu) $(mem) $(clock)"
|
||||
done
|
||||
|
||||
@@ -156,9 +156,9 @@ static void (*bartabmonfns[])(Monitor *) = { NULL /* , customlayoutfn */ };
|
||||
#if BAR_PANGO_PATCH
|
||||
static const char font[] = "monospace 11";
|
||||
#else
|
||||
static const char *fonts[] = { "SauceCodePro Nerd Font Mono:size=11:antialias=true", "monospace:size=11:antialias=true" };
|
||||
static const char *fonts[] = { "SauceCodePro Nerd Font:size=11:antialias=true", "monospace:size=11:antialias=true" };
|
||||
#endif // BAR_PANGO_PATCH
|
||||
static const char dmenufont[] = "SauceCodePro Nerd Font Mono:size=11:antialias=true";
|
||||
static const char dmenufont[] = "SauceCodePro Nerd Font:size=11:antialias=true";
|
||||
|
||||
static char c000000[] = "#000000"; // placeholder value
|
||||
|
||||
@@ -848,6 +848,7 @@ static const char *xkb_layouts[] = {
|
||||
#if !NODMENU_PATCH
|
||||
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
||||
#endif // NODMENU_PATCH
|
||||
static const char *rofidruncmd[] = {"rofi", "-show", "drun", NULL};
|
||||
static const char *dmenucmd[] = {
|
||||
"dmenu_run",
|
||||
#if !NODMENU_PATCH
|
||||
@@ -1039,6 +1040,7 @@ static const Key keys[] = {
|
||||
{ MODKEY|ControlMask, XK_z, showhideclient, {0} },
|
||||
#endif // BAR_WINTITLEACTIONS_PATCH
|
||||
{ MODKEY|ShiftMask, XK_c, killclient, {0} },
|
||||
{ MODKEY, XK_q, killclient, {0} },
|
||||
#if KILLUNSEL_PATCH
|
||||
{ MODKEY|ShiftMask, XK_x, killunsel, {0} },
|
||||
#endif // KILLUNSEL_PATCH
|
||||
@@ -1078,7 +1080,7 @@ static const Key keys[] = {
|
||||
{ MODKEY|Mod5Mask|Mod1Mask, XK_Tab, rotatelayoutaxis, {.i = -4 } }, /* flextile, 4 = secondary stack axis */
|
||||
{ MODKEY|ControlMask, XK_Return, mirrorlayout, {0} }, /* flextile, flip master and stack areas */
|
||||
#endif // FLEXTILE_DELUXE_LAYOUT
|
||||
{ MODKEY, XK_space, setlayout, {0} },
|
||||
{ MODKEY, XK_space, spawn, {.v = rofidruncmd}},
|
||||
{ MODKEY|ShiftMask, XK_space, togglefloating, {0} },
|
||||
#if MAXIMIZE_PATCH
|
||||
{ MODKEY|ControlMask|ShiftMask, XK_h, togglehorizontalmax, {0} },
|
||||
|
||||
Reference in New Issue
Block a user