I work on both Ubuntu and Windows, and just recently switched to the Sublime Text 2 editor, which is a nice cross between TextMate and vim, and runs cross platform. Everything runs as expected on Ubuntu, not so much on Windows. Here’s what you need to do to get CoffeeScript highlighting and building:
- Install Node using the new Windows installer. This also installs npm.
- Open a cmd window
- Install CoffeeScript as you would normally: npm install -g coffee-script
- Reboot - all should be loaded into your PATH variable correctly
- For highlighting, git clone jashkenas’ coffee-script-tmbundle from GitHub into
C:\Users\<User>\AppData\Roaming\Sublime Text 2\Packages\CoffeeScript
- At this point the building doesn’t work. Open up the build file:
C:\Users\<User>\...\CoffeeScript\Commands\CoffeeScript.sublime-buildand have it look like the following:
Essentially you need to remove the “path” variable that’s there and add in the “shell” variable set to true so it runs from cmd.exe.