[patch] 优化打包逻辑 控制变量为日志产出 和 安装包整合路径统一
This commit is contained in:
@@ -85,16 +85,7 @@ def main():
|
||||
result = subprocess.run(['python', 'quick_build.py'], capture_output=False)
|
||||
|
||||
if result.returncode == 0:
|
||||
# 确保输出目录正确性
|
||||
if os.path.exists('dist/main') and not os.path.exists('dist/MultiPlatformGUI'):
|
||||
print("🔄 修正输出目录名称...")
|
||||
try:
|
||||
os.rename('dist/main', 'dist/MultiPlatformGUI')
|
||||
print("✅ 已重命名为: dist/MultiPlatformGUI/")
|
||||
except Exception as e:
|
||||
print(f"⚠️ 重命名失败: {e}")
|
||||
|
||||
# 验证最终输出
|
||||
# 验证最终输出(quick_build.py 已统一输出到 MultiPlatformGUI)
|
||||
if os.path.exists('dist/MultiPlatformGUI'):
|
||||
print("\n🎉 生产环境打包成功!")
|
||||
print("📁 输出目录: dist/MultiPlatformGUI/")
|
||||
@@ -108,9 +99,7 @@ def main():
|
||||
else:
|
||||
print("⚠️ 主程序文件未找到")
|
||||
else:
|
||||
print("\n❌ 输出目录验证失败")
|
||||
if os.path.exists('dist/main'):
|
||||
print("💡 发现: dist/main/ 目录,请手动重命名为 MultiPlatformGUI")
|
||||
print("\n❌ 输出目录验证失败: 未找到 dist/MultiPlatformGUI")
|
||||
else:
|
||||
print("\n❌ 打包失败")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user