| 1234567891011121314151617181920212223242526272829303132333435 |
- name: Build Windows EXE
- on:
- push:
- tags:
- - 'v*'
- workflow_dispatch:
- jobs:
- build-windows:
- runs-on: windows-latest
- steps:
- - name: Checkout code
- uses: actions/checkout@v4
- - name: Set up Python
- uses: actions/setup-python@v5
- with:
- python-version: '3.11'
- - name: Install dependencies
- run: |
- python -m pip install --upgrade pip
- pip install -r requirements.txt
- - name: Build EXE
- run: |
- pyinstaller --onefile --console --name "沪武档案同步玄海" --collect-all mysql.connector --clean sync_measure_data.py
- - name: Upload artifact
- uses: actions/upload-artifact@v4
- with:
- name: windows-exe
- path: dist/
- retention-days: 30
|