python3转变exe的方法

python开发的代码可能在其他windows上并不能使用用,除非别人的环境中也有python。

下面是如何将python开发的东西转为exe格式

1.安装pyinstaller

pip install pyinstaller

2.跳到python文件目录下面运行命令 pyinstaller --onefile python文件名

--onefile的作用是产生的结果汇成一个exe的文件。

 

3.结果会将exe的文件输出到当前目录下的dist的下面

 

原文地址:https://www.cnblogs.com/shiguangliangchunshanbo/p/9726384.html