sublime和python
《转载》
使用 Sublime 工具时报Decode error - output not utf-8解决办法
打开Python.sublime-build文件,并添加"encoding":"cp936"这一行,保存即可
{
"cmd": ["python", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python",
"encoding":"cp936"
}
"cmd": ["python", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python",
"encoding":"cp936"
}
Python.sublime-build文件存放地址:
C:\Users\用户名\AppData\Roaming\Sublime Text 2\Packages\Python
实在找不到的话可以这样来查找:
tools->build system -> New Build System
此时会打开一个新文件,不用输入内容,直接保存,看看保存到哪里去了吧.