Posts

Showing posts with the label racket

Grab Packt With Racket

Automatically claim Packt's free e-books with a Racket program. Introduction Packt Publishing has launched a new programme called " free learning offer "; each day they put an e-book for free on their website to download: one needs to login to Packt's website and click on the "claim your free book" link. A nice fellow, wrote some Javascript code (nodejs) to be able to automatically claim a book, for example by calling the code from a cron job. He named the code "grab_packt" and has made it available on github . To me it is not fair to have only a Javascript version! So I decided to give it a go with different languages. This time I'll present the version written with Racket . The Code The code is in public domain. You can get it directly from is.gd/iRF96N or from my github gist . For this to work you need to replace YOUR-EMAIL-ADDRESS (line 24) and YOUR-PASSWORD (line 25) with reasonable values. If you wish to run this from shell/cron ...