The code for the book can be found under this github organization: https://github.com/petbattle
All of the code snippets from the book are stored in the CODE_SNIPPETS document so you can easily cut and paste them as you read the book.
If you have already purchased a print or Kindle version of this book, you can get a DRM-free PDF version at no cost.
Simply click on the link to claim your free PDF.