Skip to content

chore: simplify to manual tagging with auto version update #14

chore: simplify to manual tagging with auto version update

chore: simplify to manual tagging with auto version update #14

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
jobs:
build:
runs-on: macos-15
strategy:
matrix:
arch: [arm64, x86_64]
steps:
- uses: actions/checkout@v4
- name: Build
env:
ARCH: ${{ matrix.arch }}
run: |
xcodebuild -project open-sidenotes.xcodeproj \
-scheme open-sidenotes \
-configuration Release \
-archivePath "build/open-sidenotes-${ARCH}.xcarchive" \
-arch "${ARCH}" \
archive \
CODE_SIGN_IDENTITY="-" \
CODE_SIGNING_REQUIRED=NO \
CODE_SIGNING_ALLOWED=NO
- name: Sign app
env:
ARCH: ${{ matrix.arch }}
run: |
codesign --deep --force --sign - \
"build/open-sidenotes-${ARCH}.xcarchive/Products/Applications/open-sidenotes.app"
- name: Create DMG
env:
ARCH: ${{ matrix.arch }}
run: |
mkdir -p build/dmg
cp -R "build/open-sidenotes-${ARCH}.xcarchive/Products/Applications/open-sidenotes.app" build/dmg/
cp INSTALL.txt build/dmg/
ln -s /Applications build/dmg/Applications
hdiutil create -volname "Open Sidenotes" \
-srcfolder build/dmg \
-ov -format UDZO \
"build/open-sidenotes-${ARCH}.dmg"
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: open-sidenotes-${{ matrix.arch }}
path: build/open-sidenotes-${{ matrix.arch }}.dmg
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Download ARM artifact
uses: actions/download-artifact@v4
with:
name: open-sidenotes-arm64
- name: Download Intel artifact
uses: actions/download-artifact@v4
with:
name: open-sidenotes-x86_64
- name: Create Release
uses: softprops/action-gh-release@v2
with:
files: |
open-sidenotes-arm64.dmg
open-sidenotes-x86_64.dmg
generate_release_notes: true