desktop-prerelease #1
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: desktop-prerelease | |
| on: | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| name: build-${{ matrix.target }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: windows-latest | |
| target: win | |
| build_script: dist:win | |
| - os: macos-latest | |
| target: mac | |
| build_script: dist:mac | |
| - os: ubuntu-latest | |
| target: linux | |
| build_script: dist:linux | |
| env: | |
| CSC_IDENTITY_AUTO_DISCOVERY: "false" | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '24' | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.12' | |
| - name: Install uv | |
| run: python -m pip install --upgrade uv | |
| - name: Verify uv | |
| run: uv --version | |
| - name: Install frontend dependencies | |
| working-directory: frontend | |
| run: npm ci | |
| - name: Install desktop dependencies | |
| working-directory: desktop | |
| run: npm install | |
| - name: Build desktop artifacts | |
| working-directory: desktop | |
| run: npm run ${{ matrix.build_script }} | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: deeplab-${{ matrix.target }} | |
| path: desktop/dist/** | |
| if-no-files-found: error | |
| release: | |
| name: publish-prerelease | |
| runs-on: ubuntu-latest | |
| needs: build | |
| steps: | |
| - name: Download all artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: release-assets | |
| - name: Publish GitHub pre-release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| tag_name: pre-${{ github.run_id }} | |
| name: DeepLab Desktop Pre-release ${{ github.run_number }} | |
| prerelease: true | |
| generate_release_notes: true | |
| files: release-assets/**/* | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |