Bump actions/upload-artifact from 4 to 7 #17
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 executables (Windows + Linux) | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| name: Build on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| python: "3.13" | |
| add_data_sep: ":" | |
| - os: windows-latest | |
| python: "3.13" | |
| add_data_sep: ";" | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python }} | |
| cache: pip | |
| - name: Install Windows-only dependencies | |
| if: runner.os == 'Windows' | |
| shell: bash | |
| run: | | |
| if [ -f requirements-windows.txt ]; then pip install -r requirements-windows.txt; fi | |
| - name: Install dependencies | |
| shell: bash | |
| run: | | |
| python -m pip install --upgrade pip | |
| if [ -f requirements.txt ]; then | |
| python -m pip install -r requirements.txt | |
| fi | |
| if [ -f src/requirements.txt ]; then | |
| python -m pip install -r src/requirements.txt | |
| fi | |
| python -m pip install pyinstaller | |
| - name: Build (PyInstaller onefile) | |
| shell: bash | |
| run: | | |
| APP_NAME="dBaseRunner" | |
| ENTRYPOINT="src/dBaseRunner.py" | |
| ADD_DATA="src/icons${{ matrix.add_data_sep }}src/icons" | |
| python -m PyInstaller \ | |
| --noconfirm \ | |
| --clean \ | |
| --onefile \ | |
| --name "$APP_NAME" \ | |
| --add-data "$ADD_DATA" \ | |
| --collect-all antlr4 \ | |
| "$ENTRYPOINT" | |
| - name: Upload artifact | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: ${{ matrix.os }}-dBaseRunner | |
| path: dist/* |