improve
This commit is contained in:
19
bin/st-vol
19
bin/st-vol
@ -1,19 +1,8 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
VOLUME=$(wpctl get-volume @DEFAULT_SINK@)
|
VOLUME=$(mixer | grep vol)
|
||||||
case $VOLUME in
|
case $VOLUME in
|
||||||
*MUTED*)
|
*mute*)
|
||||||
echo " MUTED";;
|
echo " MUTED";;
|
||||||
*)
|
|
||||||
VOLUME=$(echo $VOLUME | awk '{print $2}' | sed 's/^0//;s/\.//')
|
|
||||||
echo " $VOLUME";;
|
|
||||||
esac
|
esac
|
||||||
|
VOLUME=$(echo $VOLUME | awk '{print $3}' | sed 's/:.*//;s/^0//;s/\.//')
|
||||||
# freebsd
|
echo " $VOLUME"
|
||||||
#VOLUME=$(mixer | grep vol)
|
|
||||||
#case $VOLUME in
|
|
||||||
# *muted*)
|
|
||||||
# echo " MUTED";;
|
|
||||||
# *)
|
|
||||||
# VOLUME=$(echo $VOLUME | awk '{print $3}' | sed 's/:.*//;s/^0//;s/\.//')
|
|
||||||
# echo " $VOLUME";;
|
|
||||||
#esac
|
|
||||||
|
|||||||
Reference in New Issue
Block a user