Wikipedia to my mailbox

ript>

I’m a frequent reader of Wikipedia. I’m even subscribed to “Article of the day” mailing list and every day I receive a random article to my mailbox. But when I wanted to find information about something, I had to open a new tab in my browser, visit wikipedia, find and read the article and, if there was value for me, save it for future reference… until yesterday!

Yesterday, I discovered (and installed) the wikipedia2text package and, to make things easier for me, I wrote a little wrapper function, which I promptly inserted into my ~/.bashrc:

wp() {
    what=”$*”
    wikipedia2text “$what” | mailx -s “wikipedia article: $what” myemail
}

From now on, while working on a terminal, each time I issue a

wp title-terms

a new article will be delivered to my mailbox.
Example: wp context switch


Visit The Light of the LAMP blog for more…

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.