Fix class name mapping mix up #111
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 Application | |
| on: | |
| push: | |
| branches: [ "main" ] | |
| pull_request: | |
| branches: [ "main" ] | |
| release: | |
| types: [published] | |
| jobs: | |
| build-macos: | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| lfs: 'true' | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.13' | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v6 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| uv sync --group dev | |
| - name: Build macOS app | |
| run: | | |
| source .venv/bin/activate | |
| poe build-mac | |
| - name: Zip macOS app | |
| run: | | |
| cd dist/macos | |
| zip -r Detectorist.app.zip Detectorist.app | |
| - name: Upload macOS artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: Detectorist.app.zip | |
| path: dist/macos/Detectorist.app.zip | |
| build-windows: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| lfs: 'true' | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.13' | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v6 | |
| - name: Install dependencies | |
| run: | | |
| uv venv | |
| uv sync --group dev | |
| - name: Build Windows executable | |
| run: | | |
| .\.venv\Scripts\activate | |
| poe build-windows | |
| - name: Zip Windows executable | |
| run: | | |
| Compress-Archive -Path dist/windows/Detectorist.exe -DestinationPath dist/windows/Detectorist.exe.zip | |
| - name: Upload Windows artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: Detectorist.exe.zip | |
| path: dist/windows/Detectorist.exe.zip | |
| create-release: | |
| needs: [build-macos, build-windows] | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'release' | |
| steps: | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| merge-multiple: true # downloaded artifacts directly into the current directory (instead of separate folders) | |
| - name: List contents | |
| run: ls -la | |
| - name: Upload Release Assets | |
| uses: softprops/action-gh-release@v2 | |
| if: github.ref_type == 'tag' | |
| with: | |
| files: | | |
| Detectorist.app.zip | |
| Detectorist.exe.zip | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |