打包前需要先安装 pyinstaller
pyinstaller -D -w .\MainCalc.py 多个文件,且不显示命令行
pyinstaller --onefile -w .\MainCalc.py
pyinstaller -F <script.py>:将Python脚本打包成单个可执行文件。
pyinstaller -D <script.py>:将Python脚本打包成多个文件的目录。
pyinstaller -w <script.py>:打包成Windows应用程序,没有控制台窗口。
pyinstaller -c <script.py>:打包成Windows控制台程序。
pyinstaller -p <path> <script.py>:添加依赖路径。
pyinstaller --hidden-import=<module> <script.py>:添加隐藏依赖项。
pyinstaller --onefile <script.py>:将所有依赖项打包到单个文件中。
pyinstaller --clean <script.py>:清除缓存和临时文件。