inital commit
This commit is contained in:
9
.local/bin/tools/rssadd
Executable file
9
.local/bin/tools/rssadd
Executable file
@ -0,0 +1,9 @@
|
||||
#!/bin/sh
|
||||
! echo "$1" | grep "https*://\S\+\.[A-Za-z]\+\S*" >/dev/null &&
|
||||
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 "You already have this RSS feed."
|
||||
else
|
||||
echo "$1" >> "$RSSFILE" && notify-send "RSS feed added."
|
||||
fi
|
Reference in New Issue
Block a user