Dimitar Kostov ramblings

Fixing Ruby build in Sublime Text 2

If youre getting this error while trying to run ruby script, just replace the loop in Packages/Default/exec.py on line 44 with the snippet below:

UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 60 ...
Packages/Default/exec.py:44
1
2
3
4
5
for k, v in proc_env.iteritems():
  path_vars = os.path.expandvars(v)
  if isinstance(path_vars, unicode):
      path_vars = path_vars.encode(sys.getfilesystemencoding())
  proc_env[k] = path_vars

Comments