linux下使用sublime-text写coffee遇到的编译问题
Traceback (most recent call last):
File "/opt/sublime_text/sublime_plugin.py", line 556, in run_
return self.run(edit)
File "/home/subying/.config/sublime-text-3/Packages/Better CoffeeScript/CoffeeScript.py", line 186, in run
result = run("coffee", args=args, cwd=cwd)
File "/home/subying/.config/sublime-text-3/Packages/Better CoffeeScript/CoffeeScript.py", line 43, in run
res = _run(cmd, args=args, source=source, cwd=cwd, env=env)
File "/home/subying/.config/sublime-text-3/Packages/Better CoffeeScript/CoffeeScript.py", line 74, in _run
proc = Popen(command, env=env, cwd=cwd, stdout=PIPE, stderr=PIPE)
File "./subprocess.py", line 824, in __init__
File "./subprocess.py", line 1448, in _execute_child
FileNotFoundError: [Errno 2] No such file or directory: 'coffee'
遇到了这样的问题,后面经过搜索一番,发现设置里面的 bindDir 跟系统环境中的不匹配,首先是要找到 coffee命令所在的目录,可以通过在终端输入'whereis coffee'查看。
我这里的就是将"binDir": "/usr/bin" ,改成 "binDir": "/usr/local/bin"。