内容简介:sublime text 3配置使用python
1. 在sublime text的官网下载,是适合自己系统的版本。官网地址:https://www.sublimetext.com/3
2. 安装好后,在菜单栏打开:Preferences--->Settings(这是写这个的时候,当前最新版的)
3. 打开后我们会看到这样两个文件,一个Preferences.sublime-settings--Default和Preferences.sublime-settings--User
那么这个User的文件就是我们要编辑的了
4. 在文件的大括号中写入这么一段配置信息/代码,之后保存:
1 // Settings in here override those in "Default/Preferences.sublime-settings",
2 // and are overridden in turn by syntax-specific settings.
3 {
4
5 "python":{
6 "Python":"D:/Python27/python.exe",
7 "pythonExtraPaths":
8 [
9 "D:/Python27",
10 "D:/Python27/DLLS",
11 "D:/Python27/Lib",
12 "D:/Python27/Lib/site_packages"
13 ]
14 },
15
16 }
5. 这样配置完成后,执行Ctrl-B应该是可以执行了,但是发现没有输出信息,那么就需要下面的这段配置了
File--->New File 新建一个文件,保存名称为Python.sublime-build(Python也可以写其他想些的比如 My_Python)
在里面同样需要写一段配置信息/代码,保存:
1 {
2 "shell_cmd": "d:/python27/python.exe -u \"$file\"",
3 "file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
4 "selector": "source.python",
5 "encoding":"cp936"
6 }
6. 再次执行 Ctrl-B,是不是就可以正常运行,并看到输出了(前提是你得有输出)
以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网
猜你喜欢:- SmartSql使用教程(4)——多库配置与使用
- rsync配置使用简要说明
- 使用shadowtunnel配置多级代理
- 使用Maven配置Spring
- 使用go读取配置文件
- 使用 Spell 实践深度学习,几乎零配置开始使用
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Agile Web Development with Rails, Third Edition
Sam Ruby、Dave Thomas、David Heinemeier Hansson / Pragmatic Bookshelf / 2009-03-17 / USD 43.95
Rails just keeps on changing. Rails 2, released in 2008, brings hundreds of improvements, including new support for RESTful applications, new generator options, and so on. And, as importantly, we’ve a......一起来看看 《Agile Web Development with Rails, Third Edition》 这本书的介绍吧!
JS 压缩/解压工具
在线压缩/解压 JS 代码
随机密码生成器
多种字符组合密码