{ Wilker-Dev: Blog }
August 23, 2010

Restarting server automatic with CoffeeScript (running a Node server)

Hi, this script was originally wrote in pure Javascript for Node, I just translated it to CoffeeScript in order to it work with coffeescript directly

Then just use:

coffee run_dev_server.coffee

note: while this script expects you have a file named server.coffee in same folder, you can easily change the script to fit your needs.

Aug 13, 2011
Grant Husbands said...
Typo correction: You mean self.restarting = false.

Also, you can avoid the 'self' variable by using => in place of ->