PIX variable fully removed

This commit is contained in:
Luke Smith
2019-03-20 14:45:08 -04:00
parent a0fbd46164
commit c109b22891
7 changed files with 18 additions and 18 deletions

View File

@@ -1,9 +1,9 @@
#!/bin/sh
! echo "$1" | grep "https*://\S\+\.[A-Za-z]\+\S*" >/dev/null &&
notify-send -i "$PIX/rss.svg" "That doesn't look like a full URL." && exit
notify-send "That doesn't look like a full URL." && exit
RSSFILE="$HOME/.config/newsboat/urls"
if awk '{print $1}' "$RSSFILE" | grep "^$1$" >/dev/null; then
notify-send -i "$PIX/rss.svg" "You already have this RSS feed."
notify-send "You already have this RSS feed."
else
echo "$1" >> "$RSSFILE" && notify-send -i "$PIX/rss.svg" "RSS feed added."
echo "$1" >> "$RSSFILE" && notify-send "RSS feed added."
fi