前言:由于sublime text3比较轻量,而且界面也很美观,与Python3可以友好集成,本教程就来说说Python3安装教程并集成sublime text3
环境:Windows 10
一、Python3安装
1、Python3官网下载,进入官网页面中,有2个下载选项,3.7和2.7版本,此次选择3.7版本,进行下载
![7ff83878dd7994b672ee39ae235e00b2.png](https://img-blog.csdnimg.cn/img_convert/7ff83878dd7994b672ee39ae235e00b2.png)
![9450c0a167f8ed2169316829ba7250d9.png](https://img-blog.csdnimg.cn/img_convert/9450c0a167f8ed2169316829ba7250d9.png)
2、选择3.7版本,跳转到相关页面,拉到最下面,嵌入式版本、exe安装版本和联网安装包版本,此处选择exe安装包版本进行下载
![1949793ffe621c8c7330e6c1829f8beb.png](https://img-blog.csdnimg.cn/img_convert/1949793ffe621c8c7330e6c1829f8beb.png)
![10d50d53c4c44748eb6b8f52c853715f.png](https://img-blog.csdnimg.cn/img_convert/10d50d53c4c44748eb6b8f52c853715f.png)
3、下载本地后,双击python-3.7.3-amd64.exe文件,进入安装页面,可以选择默认一键安装,也可以选择自定义安装,本文选择自定义安装
![9f4db8415b62d20ee8b7222da13ff0e2.png](https://img-blog.csdnimg.cn/img_convert/9f4db8415b62d20ee8b7222da13ff0e2.png)
![26a8e1cad8fb5c4039123473f716ceac.png](https://img-blog.csdnimg.cn/img_convert/26a8e1cad8fb5c4039123473f716ceac.png)
![82c8c317a78ef9de298756b510176a68.png](https://img-blog.csdnimg.cn/img_convert/82c8c317a78ef9de298756b510176a68.png)
4、安装完成后,快捷键win+R,输入cmd,打开dos窗口,输入Python,如果有出现Python-3.7.3,即安装成功!
![d3981a73a2da1b8255849db1c817369e.png](https://img-blog.csdnimg.cn/img_convert/d3981a73a2da1b8255849db1c817369e.png)
![fa60b7660f328198d05309fb2444d5a7.png](https://img-blog.csdnimg.cn/img_convert/fa60b7660f328198d05309fb2444d5a7.png)
二、Python3集成Sublime text3
1、下载并打开sublime text3(下载并安装请自行百度)
2、依次点击上方标题栏:Tools(工具)->Build System(编译系统)->New Build System (新编译系统),会自动弹出一个新窗口
![ff5bb142907298ea6ef99047f8538f46.png](https://img-blog.csdnimg.cn/img_convert/ff5bb142907298ea6ef99047f8538f46.png)
![43461e12a060e073f8ab07a5a45f3c26.png](https://img-blog.csdnimg.cn/img_convert/43461e12a060e073f8ab07a5a45f3c26.png)
3、用下面代码进行替换(注意Python3的安装路径)-->保存并命名
{"cmd": ["D:/work/python3/python.exe", "-u", "$file"],}
![5422587a36268d0f2f78da3a20bf0561.png](https://img-blog.csdnimg.cn/img_convert/5422587a36268d0f2f78da3a20bf0561.png)
4、配置完成后,重启Sublime,就可以看到已经集成好了(由于这个界面Windows不好截图,用了mac截的图)
![529cb47f8083604fca65b5abeccd7f5f.png](https://img-blog.csdnimg.cn/img_convert/529cb47f8083604fca65b5abeccd7f5f.png)
5、可以在sublime text3中验证一下效果
![50cf3e88a95c8cb072808b6ea4aadc93.png](https://img-blog.csdnimg.cn/img_convert/50cf3e88a95c8cb072808b6ea4aadc93.png)