Dev #20
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 (Release) | |
| on: [push, pull_request] | |
| jobs: | |
| build-macos: | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| with: | |
| submodules: true | |
| fetch-depth: 0 | |
| - name: Set short SHA | |
| run: echo "SHORT_SHA=${GITHUB_SHA::7}" >> $GITHUB_ENV | |
| - uses: DeterminateSystems/nix-installer-action@v14 | |
| - name: Build and package | |
| run: nix develop -c just create-mac-dmg | |
| - name: Remove quarantine from artifacts | |
| run: | | |
| xattr -rd com.apple.quarantine build/AsterIDE.dmg 2>/dev/null || true | |
| - uses: actions/upload-artifact@v6 | |
| with: | |
| name: asteride-macos-${{ env.SHORT_SHA }} | |
| path: build/* | |
| release: | |
| needs: [build-macos] | |
| runs-on: ubuntu-latest | |
| if: startsWith(github.ref, 'refs/tags/v') | |
| permissions: | |
| contents: write | |
| steps: | |
| - name: Set short SHA | |
| run: echo "SHORT_SHA=${GITHUB_SHA::7}" >> $GITHUB_ENV | |
| - name: Download macOS artifact | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: asteride-macos-${{ env.SHORT_SHA }} | |
| path: release | |
| - name: Create release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| prerelease: ${{ contains(github.ref_name, '-') }} | |
| draft: true | |
| files: | | |
| release/AsterIDE.dmg | |
| name: AsterIDE ${{ github.ref_name }} | |
| fail_on_unmatched_files: true |