Build Python Executable #6
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build Python Executable | |
| on: | |
| release: | |
| types: [created] | |
| jobs: | |
| build: | |
| runs-on: windows-latest | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.9' | |
| - name: Install Dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install pyinstaller numpy pandas matplotlib pymeasure pyvisa pyvisa-py Pillow | |
| - name: Build with PyInstaller using .spec file | |
| run: pyinstaller PICA_Launcher.spec | |
| - name: Upload Executable to Release | |
| uses: svenstaro/upload-release-action@v2 | |
| with: | |
| repo_token: ${{ secrets.GITHUB_TOKEN }} | |
| # --- CORRECTED FILE PATH --- | |
| file: dist/PICA_Launcher/PICA_Launcher.exe | |
| asset_name: PICA_Launcher-Windows-${{ github.ref_name }}.exe | |
| tag: ${{ github.ref }} | |
| overwrite: true |