diff --git a/.forgejo/workflows/build-appimage.yml b/.forgejo/workflows/build-appimage.yml new file mode 100644 index 0000000..13f3ff9 --- /dev/null +++ b/.forgejo/workflows/build-appimage.yml @@ -0,0 +1,73 @@ +# Claude Desktop — AppImage Build Pipeline +# Triggert bei [appimage] im Commit oder bei Release-Tags (v*) + +name: Build AppImage + +on: + push: + tags: + - 'v*' + branches: + - main + +jobs: + build: + # Nur bei [appimage] im Commit oder bei Tag + if: contains(github.event.head_commit.message, '[appimage]') || startsWith(github.ref, 'refs/tags/v') + runs-on: ubuntu-latest + container: + image: ghcr.io/tauri-apps/tauri-action-core:latest + + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '22' + cache: 'npm' + + - name: Setup Rust + uses: dtolnay/rust-toolchain@stable + + - name: Rust Cache + uses: Swatinem/rust-cache@v2 + with: + workspaces: src-tauri + + - name: Install Dependencies + run: | + apt-get update + apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf libssl-dev + + - name: Install npm packages + run: npm ci + + - name: Build Tauri App + run: npm run tauri build -- --bundles appimage + env: + TAURI_SIGNING_PRIVATE_KEY: ${{ secrets.TAURI_SIGNING_KEY }} + + - name: Get Version + id: version + run: | + VERSION=$(grep '^version' src-tauri/Cargo.toml | head -1 | sed 's/.*"\(.*\)"/\1/') + echo "version=$VERSION" >> $GITHUB_OUTPUT + echo "Version: $VERSION" + + - name: Upload AppImage Artifact + uses: actions/upload-artifact@v4 + with: + name: claude-desktop-${{ steps.version.outputs.version }}.AppImage + path: src-tauri/target/release/bundle/appimage/*.AppImage + + # Bei Tag: Release erstellen und AppImage hochladen + - name: Create Release + if: startsWith(github.ref, 'refs/tags/v') + uses: softprops/action-gh-release@v1 + with: + files: src-tauri/target/release/bundle/appimage/*.AppImage + generate_release_notes: true + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}