Sunday evening and not much to watch on the telly, so I thought I should go back to a few of the Java programs I wrote years ago and bring them into the 21st century. Wel, if you are not currently programming in Python or Django, I consider that as someone who is still hiding in a cave in the 20th century :-)
So, what better way to bring them up to date than to give then a full rewrite in Python. For me, the flexibility, syntax and power of Python is what really made me rewrite it. I love Python - having used it on many projects in the last few years, it's quite easy for me to introduce new developers into programming with Python.
However, today, the Java program I rewrote today was a Twitter program that ran from a shell. Taking search input from the user, connects to remotely to Twitter website, and collect the 10 most recent tweets containing the terms. It then goes ahead and prints the time, user name, the tweet containing our search term.
Today I added a few more features. It's now possible to configure it run continuously using your keyword, when a new tweet comes in containing the keyword, it can either send them a reply tweet, send you an SMS, email you or simply log all the tweets into a database which you can later analyse.
The cool thing about the latest script is that everything is run from a shell. Supply the necessary parameters and away you go. I got these ideas from oDesk when I used to take on on the side programming gig there. So, if you have a few hours in the evenings and on weekends, check them out for some cool and exciting quick programming task.
If anyone wants to poke around the code and probably help in polishing is a bit more or add new features, please let me know.
Now, I'm going for a Sunday evening bike ride I've been indoors since Friday night.
2017: The Year of Golang
4 months ago