Created
May 21, 2013 23:23
-
-
Save melvynhills/5624084 to your computer and use it in GitHub Desktop.
Fixes to make https://github.com/wesbos/Sublime-JS-to-CoffeeScript work on OSX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
# Fixes key command originally mapped to "html_to_jade_from_selection" | |
# ~/Library/Application Support/Sublime Text 2/Packages/Sublime-JS-to-CoffeeScript/Default (OSX).sublime-keymap | |
[ | |
{ "keys": ["shift+alt+s"], "command": "js_to_cs_from_selection"} | |
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Fixes https://github.com/nibblebot/sublime-js2coffee/issues/11 | |
# /usr/local/share/npm/lib/node_modules/js2coffee/lib/helpers.coffee | |
# L5 | |
CoffeeScript.RESERVED = require '../../coffee-script/lib/coffee-script/lexer' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Fixes https://github.com/nibblebot/sublime-js2coffee/issues/5 | |
# ~/Library/Application Support/Sublime Text 2/Packages/Sublime-JS-to-CoffeeScript/jstocoffee.py | |
# L6 | |
import os | |
my_env = os.environ.copy() | |
my_env["PATH"] = "/usr/local/bin:/usr/local/sbin:/usr/local/share/npm/bin:" + my_env["PATH"] | |
#L15 | |
p = subprocess.Popen(cmd, env=my_env, shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment