# cimery — Release build workflow (ADR-003 A3) # Triggered by pushing a version tag: git tag v0.1.0 && git push --tags # # Builds: # - Windows x64 binary (cimery-viewer.exe) # - macOS arm64 binary (cimery-viewer) # - Linux x64 binary (cimery-viewer) # # Artifacts are uploaded to the GitHub Release. # Code signing: placeholder (Azure Trusted Signing — ADR-003 A3). name: Release on: push: tags: - 'v*' permissions: contents: write env: CARGO_TERM_COLOR: always jobs: build: name: build (${{ matrix.target }}) runs-on: ${{ matrix.os }} strategy: matrix: include: - os: windows-latest target: x86_64-pc-windows-msvc artifact: cimery-viewer.exe archive: cimery-viewer-windows-x64.zip - os: macos-latest target: aarch64-apple-darwin artifact: cimery-viewer archive: cimery-viewer-macos-arm64.tar.gz - os: ubuntu-latest target: x86_64-unknown-linux-gnu artifact: cimery-viewer archive: cimery-viewer-linux-x64.tar.gz steps: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@stable with: targets: ${{ matrix.target }} - uses: Swatinem/rust-cache@v2 - name: Build release (PureRust — no OCCT for CI) run: cargo build --release -p cimery-viewer --target ${{ matrix.target }} - name: Package (Windows) if: matrix.os == 'windows-latest' shell: pwsh run: | $bin = "target/${{ matrix.target }}/release/${{ matrix.artifact }}" Compress-Archive -Path $bin -DestinationPath ${{ matrix.archive }} - name: Package (Unix) if: matrix.os != 'windows-latest' run: | bin="target/${{ matrix.target }}/release/${{ matrix.artifact }}" tar czf ${{ matrix.archive }} -C "$(dirname $bin)" "$(basename $bin)" - name: Upload to Release uses: softprops/action-gh-release@v2 with: files: ${{ matrix.archive }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # ── Nightly channel tag ──────────────────────────────────────────────────── # Tag convention: nightly/, beta/v*, stable/v* (ADR-003 A3) create-release-notes: needs: build runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - name: Generate changelog since last tag run: | PREV=$(git describe --tags --abbrev=0 HEAD^ 2>/dev/null || echo "") if [ -n "$PREV" ]; then git log ${PREV}..HEAD --oneline > RELEASE_NOTES.md else git log --oneline > RELEASE_NOTES.md fi - name: Update Release Notes uses: softprops/action-gh-release@v2 with: body_path: RELEASE_NOTES.md env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}