Hackernews In Your Inbox
If you do not want to subscribe to any newsletter but still want to get some news delivered to you inbox then this post is for you.
First you need to get a script that can pull the hacker-news articles for you and you can find my script here. You can modify this script, specially the line: for id in trending_list[:50]:
to change the number of posts that you would like to see in the mail.
Once you have done that, all you need to do is configure this in crontab, like so : @reboot sleep 600 && (echo "Subject: Hacker news for $(date +%F)"; echo; python ~/Dropbox/personal/myscripts/python/hacker-news.py) |sendmail root
. This will run the script everytime your system boots up and uses the system configured sendmail (could be sendmail or postfix) to send mail to root user.
Related Articles:
- 2022/04/23 Firefox addons for hacking
- 2022/03/06 mussh-run-commands-on-multiple-hosts
- 2022/02/09 virt-install with cloud-init
- 2022/02/05 Stay safe from phising
- 2022/01/09 Curl to exapnd short url
Authored By Amit Agarwal
Amit Agarwal, Linux and Photography are my hobbies.Creative Commons Attribution 4.0 International License.