summaryrefslogtreecommitdiffstats
path: root/shotrss
Side-by-side diff
Diffstat (limited to 'shotrss') (more/less context) (ignore whitespace changes)
-rwxr-xr-xshotrss5
1 files changed, 3 insertions, 2 deletions
diff --git a/shotrss b/shotrss
index e304f5b..5ed3eb6 100755
--- a/shotrss
+++ b/shotrss
@@ -6,9 +6,10 @@ linum=$(( $RANDOM%$lines ))
url=$(sed -n -e ${linum}p $file | awk '{ print $1 }')
dbfile="$HOME/.local/share/newsbeuter/cache.db"
-material=$(sqlite3 -separator ' | ' $dbfile "select title,url from rss_item where feedurl='$url' ORDER BY pubDate DESC LIMIT 5;" |\
+material=$(sqlite3 -separator ' # ' $dbfile "select title,url from rss_item where feedurl='$url' ORDER BY pubDate DESC LIMIT 5;" |\
sed -n -e $(( $RANDOM % 5 + 1 ))p)
-echo "$material"
+echo "$material[(ws:#:)2]"
+echo "$material" > ~/.current
exec &>/dev/null
pidof w3m || exit 0
winum=$(~/bin/tux tnum w3m)