diff options
author | Shubham Saini <shubham6405@gmail.com> | 2020-05-18 14:55:32 +0000 |
---|---|---|
committer | Shubham Saini <shubham6405@gmail.com> | 2020-05-18 14:55:32 +0000 |
commit | 8c65a77150db1013d5be1eff3711461de21e0da0 (patch) | |
tree | 1d37311dbc7a2cfe15d3028e6727386289e78de1 /dwm/dwmbar | |
parent | 8ea51c85accb4fb955bca4653ed3fb4140bb85e9 (diff) |
finally done
Diffstat (limited to 'dwm/dwmbar')
-rwxr-xr-x | dwm/dwmbar | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -1,22 +1,22 @@ | |||
1 | #!/bin/bash | 1 | #!/bin/bash |
2 | vol(){ | 2 | vol(){ |
3 | vol=$(pulsemixer --get-volume | awk '{print $1}') | 3 | vol=$(pulsemixer --get-volume | awk '{print $1}') |
4 | echo -e "\x01vol \x02$vol%" | 4 | printf "%s" "vol ^c#c6c8d1^$vol%^d^" |
5 | } | 5 | } |
6 | 6 | ||
7 | bat() { | 7 | bat() { |
8 | power=$(cat /sys/class/power_supply/BAT0/capacity) | 8 | power=$(cat /sys/class/power_supply/BAT0/capacity) |
9 | echo -e "\x01bat \x02$power%" | 9 | printf "%s" "bat ^c#c6c8d1^$power%^d^" |
10 | } | 10 | } |
11 | 11 | ||
12 | dte() { | 12 | dte() { |
13 | dte=$(date +"%A, %B %d") | 13 | dte=$(date +"%A, %B %d") |
14 | echo -e "\x01date \x02$dte" | 14 | printf "%s" "date ^c#c6c8d1^$dte^d^" |
15 | } | 15 | } |
16 | 16 | ||
17 | tie() { | 17 | tie() { |
18 | tme=$(date +"%I:%M %p") | 18 | tme=$(date +"%I:%M %p") |
19 | echo -e "\x01time \x02$tme" | 19 | printf "%s" "time ^c#c6c8d1^$tme^d^" |
20 | } | 20 | } |
21 | while true; do | 21 | while true; do |
22 | xsetroot -name "$(vol) $(bat) $(tie) $(dte)" | 22 | xsetroot -name "$(vol) $(bat) $(tie) $(dte)" |