修复前景色不显示的问题,冻结依赖,准备打包
Showing
4 changed files
with
42 additions
and
21 deletions
| ... | @@ -6,14 +6,14 @@ echo "Building Gemini Image Generator" | ... | @@ -6,14 +6,14 @@ echo "Building Gemini Image Generator" |
| 6 | echo "================================" | 6 | echo "================================" |
| 7 | 7 | ||
| 8 | # Check if virtual environment exists | 8 | # Check if virtual environment exists |
| 9 | if [ ! -d "venv" ]; then | 9 | if [ ! -d ".venv" ]; then |
| 10 | echo "Creating virtual environment..." | 10 | echo "Creating virtual environment..." |
| 11 | python3 -m venv venv | 11 | /opt/homebrew/bin/python3.11 -m venv .venv |
| 12 | fi | 12 | fi |
| 13 | 13 | ||
| 14 | # Activate virtual environment | 14 | # Activate virtual environment |
| 15 | echo "Activating virtual environment..." | 15 | echo "Activating virtual environment..." |
| 16 | source venv/bin/activate | 16 | source .venv/bin/activate |
| 17 | 17 | ||
| 18 | # Install dependencies | 18 | # Install dependencies |
| 19 | echo "Installing dependencies..." | 19 | echo "Installing dependencies..." |
| ... | @@ -30,7 +30,7 @@ pyinstaller --name="ZB100ImageGenerator" \ | ... | @@ -30,7 +30,7 @@ pyinstaller --name="ZB100ImageGenerator" \ |
| 30 | --onefile \ | 30 | --onefile \ |
| 31 | --windowed \ | 31 | --windowed \ |
| 32 | --add-data "config.json:." \ | 32 | --add-data "config.json:." \ |
| 33 | image_generator_qt.py | 33 | image_generator.py |
| 34 | 34 | ||
| 35 | # Check if build was successful | 35 | # Check if build was successful |
| 36 | if [ -f "dist/ZB100ImageGenerator.app/Contents/MacOS/ZB100ImageGenerator" ] || [ -f "dist/ZB100ImageGenerator" ]; then | 36 | if [ -f "dist/ZB100ImageGenerator.app/Contents/MacOS/ZB100ImageGenerator" ] || [ -f "dist/ZB100ImageGenerator" ]; then | ... | ... |
| ... | @@ -6,14 +6,14 @@ echo Building Gemini Image Generator | ... | @@ -6,14 +6,14 @@ echo Building Gemini Image Generator |
| 6 | echo ================================ | 6 | echo ================================ |
| 7 | 7 | ||
| 8 | REM Check if virtual environment exists | 8 | REM Check if virtual environment exists |
| 9 | if not exist "venv" ( | 9 | if not exist ".venv" ( |
| 10 | echo Creating virtual environment... | 10 | echo Creating virtual environment... |
| 11 | python -m venv venv | 11 | python -m venv .venv |
| 12 | ) | 12 | ) |
| 13 | 13 | ||
| 14 | REM Activate virtual environment | 14 | REM Activate virtual environment |
| 15 | echo Activating virtual environment... | 15 | echo Activating virtual environment... |
| 16 | call venv\Scripts\activate.bat | 16 | call .venv\Scripts\activate.bat |
| 17 | 17 | ||
| 18 | REM Install dependencies | 18 | REM Install dependencies |
| 19 | echo Installing dependencies... | 19 | echo Installing dependencies... |
| ... | @@ -33,7 +33,7 @@ pyinstaller --name="ZB100ImageGenerator" ^ | ... | @@ -33,7 +33,7 @@ pyinstaller --name="ZB100ImageGenerator" ^ |
| 33 | --windowed ^ | 33 | --windowed ^ |
| 34 | --icon=zb100_kehuan.ico ^ | 34 | --icon=zb100_kehuan.ico ^ |
| 35 | --add-data "config.json;." ^ | 35 | --add-data "config.json;." ^ |
| 36 | image_generator_qt.py | 36 | image_generator.py |
| 37 | 37 | ||
| 38 | REM Check if build was successful | 38 | REM Check if build was successful |
| 39 | if exist "dist\ZB100ImageGenerator.exe" ( | 39 | if exist "dist\ZB100ImageGenerator.exe" ( | ... | ... |
| ... | @@ -14,7 +14,6 @@ from PySide6.QtCore import Qt, QThread, Signal, QSize | ... | @@ -14,7 +14,6 @@ from PySide6.QtCore import Qt, QThread, Signal, QSize |
| 14 | from PySide6.QtGui import QPixmap, QFont, QIcon, QDesktopServices | 14 | from PySide6.QtGui import QPixmap, QFont, QIcon, QDesktopServices |
| 15 | from PySide6.QtCore import QUrl | 15 | from PySide6.QtCore import QUrl |
| 16 | 16 | ||
| 17 | from PIL import Image | ||
| 18 | import base64 | 17 | import base64 |
| 19 | import io | 18 | import io |
| 20 | import json | 19 | import json |
| ... | @@ -250,7 +249,8 @@ class LoginDialog(QDialog): | ... | @@ -250,7 +249,8 @@ class LoginDialog(QDialog): |
| 250 | self.show_error("请输入用户名") | 249 | self.show_error("请输入用户名") |
| 251 | return | 250 | return |
| 252 | 251 | ||
| 253 | if not password_input: | 252 | # Check if password is provided or saved password exists |
| 253 | if not password_input and not self.saved_password_hash: | ||
| 254 | self.show_error("请输入密码") | 254 | self.show_error("请输入密码") |
| 255 | return | 255 | return |
| 256 | 256 | ... | ... |
| 1 | # Qt GUI 版本依赖 | 1 | altgraph==0.17.5 |
| 2 | # 核心依赖 | 2 | annotated-types==0.7.0 |
| 3 | google-genai>=1.0.0,<2.0.0 | 3 | anyio==4.12.0 |
| 4 | Pillow>=10.0.0,<11.0.0 | 4 | cachetools==6.2.2 |
| 5 | PyQt5>=5.15.0,<6.0.0 | 5 | certifi==2025.11.12 |
| 6 | 6 | charset-normalizer==3.4.4 | |
| 7 | # 数据库依赖 | 7 | google-auth==2.43.0 |
| 8 | pymysql>=1.0.0,<2.0.0 | 8 | google-genai==1.52.0 |
| 9 | 9 | h11==0.16.0 | |
| 10 | # 打包工具 | 10 | httpcore==1.0.9 |
| 11 | pyinstaller>=6.0.0,<7.0.0 | 11 | httpx==0.28.1 |
| 12 | idna==3.11 | ||
| 13 | macholib==1.16.4 | ||
| 14 | packaging==25.0 | ||
| 15 | pyasn1==0.6.1 | ||
| 16 | pyasn1_modules==0.4.2 | ||
| 17 | pydantic==2.12.5 | ||
| 18 | pydantic_core==2.41.5 | ||
| 19 | pyinstaller==6.17.0 | ||
| 20 | pyinstaller-hooks-contrib==2025.10 | ||
| 21 | PyMySQL==1.1.2 | ||
| 22 | PySide6==6.10.1 | ||
| 23 | PySide6_Addons==6.10.1 | ||
| 24 | PySide6_Essentials==6.10.1 | ||
| 25 | requests==2.32.5 | ||
| 26 | rsa==4.9.1 | ||
| 27 | shiboken6==6.10.1 | ||
| 28 | tenacity==9.1.2 | ||
| 29 | typing-inspection==0.4.2 | ||
| 30 | typing_extensions==4.15.0 | ||
| 31 | urllib3==2.5.0 | ||
| 32 | websockets==15.0.1 | ... | ... |
-
Please register or sign in to post a comment