os/arch (lemonbar): update lemons

This commit is contained in:
Henrik Lissner 2017-01-03 03:49:10 -05:00
parent f364e7dd53
commit e3c731f35e
3 changed files with 8 additions and 12 deletions

View file

@ -7,11 +7,9 @@ if [[ ! -f ~/.private/config/email.conf ]]; then
exit 1 exit 1
fi fi
. ~/.private/config/email.conf . $HOME/.private/config/email.conf
. $CWD/../panel-config . $CWD/../panel-config
ICON_MAIL=""
get_mail() { get_mail() {
local feed=$(curl -u "$1:$2" --silent https://mail.google.com/mail/feed/atom) local feed=$(curl -u "$1:$2" --silent https://mail.google.com/mail/feed/atom)
if [[ "${feed//\<fullcount\>/}" != "$feed" ]]; then if [[ "${feed//\<fullcount\>/}" != "$feed" ]]; then

View file

@ -1,8 +1,7 @@
#!/usr/bin/env dash #!/usr/bin/env dash
# I expect all volume adjustments to be done through the volume.sh script (in # I expect all volume adjustments to be done through vol.sh (in os/arch/bin), which will
# os/arch/bin), which will inform lemonbar of changes, so we only need to intialize # inform lemonbar of changes, so we only need to intialize volume once here.
# volume once here.
. $(dirname $0)/../panel-config . $(dirname $0)/../panel-config
@ -11,10 +10,9 @@ vol=0
if echo "$data" | grep '\[on\]' >/dev/null; then if echo "$data" | grep '\[on\]' >/dev/null; then
vol=$(echo "$data" | sed -n 's/^.*\[\([0-9]\+\)%.*$/\1/p' | uniq) vol=$(echo "$data" | sed -n 's/^.*\[\([0-9]\+\)%.*$/\1/p' | uniq)
case $vol in case $vol in
0) echo "V${ICON_MUTED}" 0) echo "V${ICON_MUTED} " ;;
;; [1-7]|[1-7][0-9]) echo "V${ICON_SPEAKER_LOW} " ;;
*) echo "V${ICON_SPEAKER}" *) echo "V${ICON_SPEAKER}" ;;
;;
esac esac
else else
echo "V%{F${COLOR_DIM}}${ICON_MUTED}%{F-}" echo "V%{F${COLOR_DIM}}${ICON_MUTED}%{F-}"