display nothing with zero unread articles

This commit is contained in:
Alexander Bocken 2020-12-29 16:44:12 +01:00
parent 134d1fab3d
commit 99e8109bf0
Signed by: Alexander
GPG Key ID: 1D237BE83F9B05E8

View File

@ -1,6 +1,6 @@
#!/bin/bash
#!/bin/sh
num="$(newsboat -x print-unread | cut -f1 -d ' ' )"
if ! pgrep newsboat > /dev/null ; then
[ "$num" = "" ] || printf "📰%s" "$num"
[ "$num" = "0" ] || printf "📰%s" "$num"
printf '\n'
fi