python3转变exe的方法

原文链接: https://blog.csdn.net/qq_38656841/article/details/82921951

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

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

1.安装pyinstaller

pip install pyinstaller
python3转变exe的方法_第1张图片

2.跳到需要转为exe文件的python文件目录下面,运行命令 pyinstaller --onefile python文件名

–onefile的作用是产生的结果汇成一个exe的文件。
python3转变exe的方法_第2张图片

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

python3转变exe的方法_第3张图片

————————————————
原文链接:https://blog.csdn.net/qq_38656841/article/details/82921951

你可能感兴趣的:(python)