mirror of
https://git.adityakumar.xyz/dwmbar.git
synced 2024-11-21 18:12:53 +00:00
Updated TODO and changed bc to python in volumebar
This commit is contained in:
parent
20b9b4855e
commit
13168d33d4
2 changed files with 2 additions and 5 deletions
5
TODO.org
5
TODO.org
|
@ -10,10 +10,7 @@ Each module writes to stdout.
|
||||||
/home/$USER/.config/dwmbar/modules/
|
/home/$USER/.config/dwmbar/modules/
|
||||||
|
|
||||||
* Todo List
|
* Todo List
|
||||||
- Delay in archupdates module (if minutes divisible by 5/4)
|
nothing :D
|
||||||
- python3 instead of bc
|
|
||||||
- User can specify the separator between each module
|
|
||||||
- Fix weather module
|
|
||||||
|
|
||||||
Bugs to fix:
|
Bugs to fix:
|
||||||
none
|
none
|
||||||
|
|
|
@ -18,7 +18,7 @@ get_volume(){
|
||||||
active_sink=$(pacmd list-sinks | awk '/* index:/{print $3}')
|
active_sink=$(pacmd list-sinks | awk '/* index:/{print $3}')
|
||||||
curStatus=$(pacmd list-sinks | grep -A 15 "index: $active_sink$" | awk '/muted/{ print $2}')
|
curStatus=$(pacmd list-sinks | grep -A 15 "index: $active_sink$" | awk '/muted/{ print $2}')
|
||||||
volume=$(pacmd list-sinks | grep -A 15 "index: $active_sink$" | grep 'volume:' | grep -E -v 'base volume:' | awk -F : '{print $3}' | grep -o -P '.{0,3}%'| sed s/.$// | tr -d ' ')
|
volume=$(pacmd list-sinks | grep -A 15 "index: $active_sink$" | grep 'volume:' | grep -E -v 'base volume:' | awk -F : '{print $3}' | grep -o -P '.{0,3}%'| sed s/.$// | tr -d ' ')
|
||||||
slider_position=$(echo "scale=scale(1.0); x = ($volume / 100) * $VOLUME_WIDTH; scale=scale(1); x / 1" | bc)
|
slider_position=$(python -c "print(($volume / 100) * $VOLUME_WIDTH)")
|
||||||
|
|
||||||
if [ "${curStatus}" = 'yes' ]
|
if [ "${curStatus}" = 'yes' ]
|
||||||
then
|
then
|
||||||
|
|
Loading…
Reference in a new issue