build: add pyinstaller packaging
Tests / Python 3.11 / Windows (push) Has been cancelled

This commit is contained in:
chengma
2026-07-03 09:26:27 +08:00
parent dd2a8e3360
commit 6d4f60fcdb
12 changed files with 309 additions and 12 deletions
+55
View File
@@ -0,0 +1,55 @@
# -*- mode: python ; coding: utf-8 -*-
"""PyInstaller spec for cmshopee Windows onedir builds.
Local user data is intentionally not bundled. The release package must not
include config files, SQLite databases, Chrome profiles, generated images,
logs, prompts, or other operator data.
"""
block_cipher = None
a = Analysis(
["main.py"],
pathex=[],
binaries=[],
datas=[],
hiddenimports=[
"PySide6.QtCore",
"PySide6.QtGui",
"PySide6.QtWidgets",
],
hookspath=[],
hooksconfig={},
runtime_hooks=[],
excludes=[],
win_no_prefer_redirects=False,
win_private_assemblies=False,
cipher=block_cipher,
noarchive=False,
)
pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher)
exe = EXE(
pyz,
a.scripts,
[],
exclude_binaries=True,
name="cmshopee",
debug=False,
bootloader_ignore_signals=False,
strip=False,
upx=True,
console=False,
disable_windowed_traceback=False,
)
coll = COLLECT(
exe,
a.binaries,
a.zipfiles,
a.datas,
strip=False,
upx=True,
upx_exclude=[],
name="cmshopee",
)