This commit is contained in:
2026-08-26 11:41:26 +08:00
parent 17966a342b
commit dd80d265ac
12 changed files with 206 additions and 80 deletions
+9 -10
View File
@@ -1,24 +1,23 @@
@echo off
chcp 65001 >nul
REM ============================================================
REM 打包客户端桌面版为单个 exe
REM 产物:dist\Boss直聘AI投递.exe
REM 使用:把 exe 复制到项目根目录(与 client 目录同级)双击运行,
REM client\.env 等配置照常生效。
REM 打包客户端桌面版(PySide6 + QtWebEngine,Win10/11 通用,零系统依赖)
REM 产物:dist\Boss直聘AI投递\ 文件夹(内含 exe 及运行时)
REM 使用:把整个文件夹拷到目标机器(或压缩成 zip 发送),
REM 双击文件夹里的 Boss直聘AI投递.exe 运行。
REM ============================================================
echo [1/2] 安装打包依赖...
pip install pyinstaller pywebview --quiet
pip install pyinstaller PySide6 --quiet
if errorlevel 1 (
echo 依赖安装失败,请检查 Python 环境
pause & exit /b 1
)
echo [2/2] PyInstaller 打包中(首次较慢,请耐心等待)...
pyinstaller --noconfirm --clean --onefile --windowed ^
echo [2/2] PyInstaller 打包中(Qt 体积大,首次较慢,请耐心等待)...
pyinstaller --noconfirm --clean --onedir --windowed ^
--name "Boss直聘AI投递" ^
--collect-all uvicorn ^
--collect-all webview ^
--add-data "client\web\templates;client\web\templates" ^
--add-data "client\web\static;client\web\static" ^
client\desktop.py
@@ -28,6 +27,6 @@ if errorlevel 1 (
)
echo.
echo 打包完成:dist\Boss直聘AI投递.exe
echo 请将该 exe 复制到项目根目录(与 client 文件夹同级)后双击运行。
echo 打包完成:dist\Boss直聘AI投递\Boss直聘AI投递.exe
echo 请将 dist\Boss直聘AI投递 整个文件夹拷贝到目标机器后双击 exe 运行。
pause