diff options
Diffstat (limited to '')
-rwxr-xr-x | .local/bin/status/sb-mailbox | 21 | ||||
-rwxr-xr-x | .local/bin/status/sb-memory | 2 |
2 files changed, 18 insertions, 5 deletions
diff --git a/.local/bin/status/sb-mailbox b/.local/bin/status/sb-mailbox index ed41b03..21a9ab0 100755 --- a/.local/bin/status/sb-mailbox +++ b/.local/bin/status/sb-mailbox @@ -13,8 +13,21 @@ case $BLOCK_BUTTON in 6) "$TERMINAL" -e "$EDITOR" "$0" ;; esac -unread="$(ls "${MAIL:-/var/mail/jozan}"/bousset.rudy@gmail.com/INBOX/new/ | wc -l 2>/dev/null)" +icon="" -pidof mbsync >/dev/null 2>&1 && icon="" -[ "$icon" = "" ] && icon="" -[ "$unread" -eq 0 ] || echo "$icon " $unread +mb_a="$(ls "${MAIL:-/var/mail/jozan}"/bousset.rudy@gmail.com/INBOX/new/ | wc -l 2>/dev/null)" +if [ "$mb_a" -gt 0 ]; then + echo -n " $icon A:" $mb_a +fi + +mb_b="$(ls "${MAIL:-/var/mail/jozan}"/olsen.oyvind.nor@gmail.com/INBOX/new/ | wc -l 2>/dev/null)" +if [ "$mb_b" -gt 0 ]; then + echo -n " $icon B:" $mb_b +fi + +mb_c="$(ls "${MAIL:-/var/mail/jozan}"/rbousset@secuserve.com/INBOX/new/ | wc -l 2>/dev/null)" +if [ "$mb_c" -gt 0 ]; then + echo -n " $icon C:" $mb_c +fi + +pidof mbsync >/dev/null 2>&1 && echo " " diff --git a/.local/bin/status/sb-memory b/.local/bin/status/sb-memory index 0a9221c..2ab06bd 100755 --- a/.local/bin/status/sb-memory +++ b/.local/bin/status/sb-memory @@ -1,3 +1,3 @@ #!/bin/sh -freecolor -o | sed -n '2p' | awk '{printf (" %2.2fGB/%2.2fGB\n", ($3 / (1024 ^ 2)), ($2 / (1024 ^ 2)))}' +freecolor -o | sed -n '2p' | awk '{printf (" %2.2fG/%2.2fG\n", ($3 / (1024 ^ 2)), ($2 / (1024 ^ 2)))}' |