Skip to content

Instantly share code, notes, and snippets.

@Roman2K
Created February 6, 2012 16:32
Show Gist options
  • Save Roman2K/1753140 to your computer and use it in GitHub Desktop.
Save Roman2K/1753140 to your computer and use it in GitHub Desktop.
Debugging CoffeeScript
#!/bin/bash
file=$1
filename=$(basename "$file")
tmp_filename=${filename%.coffee}.$RANDOM.js
out="/tmp/$tmp_filename"
coffee -s -c < "$file" > "$out" || exit 1
"$EDITOR" "$out" && rm -f "$out"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment