diff options
Diffstat (limited to 'spectrwm')
-rwxr-xr-x | spectrwm/.config/spectrwm/statusbar | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/spectrwm/.config/spectrwm/statusbar b/spectrwm/.config/spectrwm/statusbar new file mode 100755 index 0000000..c90c1df --- /dev/null +++ b/spectrwm/.config/spectrwm/statusbar | |||
@@ -0,0 +1,30 @@ | |||
1 | #!/bin/bash | ||
2 | |||
3 | BOLD='\033[1m' | ||
4 | BB='\033[00m' | ||
5 | |||
6 | vol(){ | ||
7 | vol=$(pulsemixer --get-volume | awk '{print $1}') | ||
8 | echo -e "+@fg=1;vol+@fg=0; $vol% " | ||
9 | } | ||
10 | |||
11 | bat() { | ||
12 | power=$(cat /sys/class/power_supply/BAT0/capacity) | ||
13 | echo -e "+@fg=1;bat+@fg=0; $power% " | ||
14 | } | ||
15 | |||
16 | dte() { | ||
17 | dte=$(date +"%A, %B %d") | ||
18 | echo -e "+@fg=1;date+@fg=0; $dte " | ||
19 | } | ||
20 | |||
21 | tie() { | ||
22 | tme=$(date +"%I:%M %p") | ||
23 | echo -e "+@fg=1;time+@fg=0; $tme " | ||
24 | } | ||
25 | |||
26 | while :; do | ||
27 | echo "$(vol) $(bat) $(tie) $(dte)" | ||
28 | sleep 2 | ||
29 | done | ||
30 | |||