Download All of Hackles Archive and More…

I was looking at a script written by my friend Chinmay which downloads all the archives from XKCD.com. It’s a nice script. I was looking for something like that and I found it. The downsides of that script are (sorry Chinmay), it does not download the files to a specific directory. They get downloaded in the same directory as the script. Second is, the images are raw (not in a formatted manner) and the script does not download captions.

Let me tell you little about hackles. From the site, it quotes,

Hackles is our hero, the hapless programmer dog. Like many dogs, he is friendly and just wants to get along with his officemates. He doesn’t care about (or have the knack for) office politics or creating conflict. More often than not, he prefers to be left alone to code and drink massive amounts of coffee. A true techie, Hackles is somewhat of a nerd, enjoying Dungeons and Dragons, watching the Sci-Fi Channel, and building robots.

Interesting, right? Well, there are more characters… (evil penguins too… ;) )… It is great comic… too bad it was discontinued. :(

Let me admit it at the start, I am poor at shell scripting (cause I have never tried to learn it) and learning python. So, with a lot of help from internet and many guys from IRC, I got the basics cleared and voila, wrote a script that downloads all the archives from hackles, saves them in the directory YOU want AND also creates an HTML out of it, with all the cartoons AND their captions too…

Just check it out. I am giving the source here. Hope you will like it, and use it. All suggestions, criticisms, etc are welcome…. :p

UPDATE :- I just checked the entire code, and there seems to be a little problem with fetching the caption for some cartoons. I will look into it once my exams are over and will put up an updated version. Till then, enjoy this.

Download the File

UPDATE :- I knew I said I will work on this after exams, but I could not stop and with some help from QwertyM, I finished the script with some improvements.

Download the New Improved File

Tags: , , , , , ,

This entry was posted on Friday, October 17th, 2008 at 12:18 am and is filed under Humour, Internet, Linux, Programming. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

5 Responses to “Download All of Hackles Archive and More…”

ray|raven October 17th, 2008 at 8:59 am

ZOMG , PYTHON!!!
You traitor , you ditch teh awesome bash for python!! , you will pay :p

Now that my rant is over , i gotta admit the idea of creating a html is neat. I gotta try write that in bash for my garfield script.

Aditya October 17th, 2008 at 10:47 am

Hehe… Well, as I said, I am yet to learn bash scripting in detail. And I don’t think creating HTML in bash would have been easy.

Next version, based on beautifulSoup and comics html written using a css file… This time, it is going to be after exams for sure….

Quiz_Master October 17th, 2008 at 6:57 pm

How do I use that python script in Windhos? LOL kidding!
Nice one dude!

Chinmay Kamat October 17th, 2008 at 8:08 pm

See….despite all ur complaints…”I” inspire u to do good things..U should thank me for that again …

Fun aside….looks like u are really doing well in python now….now how about continuing ur idea abt making one for XKCD ..

Harsh October 18th, 2008 at 11:41 am

@ray|raven - Bash?! At least Python is cross platform! Even this script would run with simple path changes. :mrgreen:

@aditya - Mind poisoning! You must not fall to the dark side of the shell programming languages, its always about money! ($) :P

Leave a Reply