Pre-compile CoffeeScript

This PR contains two commits:

* Lock the `coffee-script` version. The latest version of coffee has a bug that prevents the use of leading dots when chaining calls. In addition, it changes the syntax of register `.coffee` extensions slightly.
* Add a `build` task to the `Makefile` and a prepublish hook that runs tests and compiles the coffeescript.