]> git.armaanb.net Git - bin.git/blobdiff - tweet-grab
tweet-grab: cleanup
[bin.git] / tweet-grab
index e6770a4fe11142b27c3c80b1daa9bfc5627cd76a..b6e7fc091da43fc04eecbbb932acbe6b8b93b2c5 100755 (executable)
@@ -6,8 +6,8 @@
 
 FILE=/root/tweets/index.html
 LOGFILE=/root/tweets/cron.log
+INSTANCE=https://nitter.fdn.fr
 
-> $FILE
-curl https://nitter.net/keshinko | grep tweet-content | head -n 1 | sed -e 's/<[^>]*>//g' -e 's/^[ \t]*\(.*$\)/\1/' >> $FILE
-tail -n 1000 $LOGFILE > $LOGFILE
-date -R >> $LOGFILE
+curl $INSTANCE/keshinko | grep tweet-content | head -n 1 \
+  | sed -e 's/<[^>]*>//g' -e 's/^[ \t]*\(.*$\)/\1/' > $FILE
+date -R > $LOGFILE