Skip to content

Update Qaterial

Update Qaterial #16

Workflow file for this run

name: 👷 MacOs CI
on:
push:
branches:
- master
- ci
release:
types:
- created
pull_request:
branches:
- master
jobs:
BuildDmg:
runs-on: macOS-latest
strategy:
matrix:
min-osx-target: ['11.0']
qt-version: ['5.15.2']
build-type: ['Release']
# 1 is legacy build system
# 12 is new build system
build-system: ['12']
steps:
-
uses: actions/checkout@v2
-
uses: OlivierLDff/import-codesign-certs@v1
with:
p12-file-base64: ${{ secrets.MAC_DMG_CERTIFICATES_FILE_BASE64 }}
p12-password: ${{ secrets.MAC_DMG_CERTIFICATES_PASSWORD }}
-
uses: OlivierLDff/download-provisioning-profiles@master
with:
bundle-id: com.qaterial.gallery
profile-type: 'MAC_APP_DIRECT'
issuer-id: ${{ secrets.MAC_APPSTORE_ISSUER_ID }}
api-key-id: ${{ secrets.MAC_APPSTORE_KEY_ID }}
api-private-key: ${{ secrets.MAC_APPSTORE_PRIVATE_KEY }}
-
name: Cache Qt
id: cache-qt-macos
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/Qt-${{ runner.os }}-${{ matrix.qt-version }}
key: ${{ runner.os }}-QtCache-${{ matrix.qt-version }}
-
name: ⬆ Install Qt
uses: jurplel/install-qt-action@v2
with:
version: ${{ matrix.qt-version }}
dir: ${{ github.workspace }}/Qt-${{ runner.os }}-${{ matrix.qt-version }}
cached: ${{ steps.cache-qt-macos.outputs.cache-hit }}
-
name: 🔧 Configure
run: |
mkdir -p build
cmake \
-G "Xcode" \
-Tbuildsystem=${{ matrix.build-system }} \
-DCMAKE_OSX_ARCHITECTURES="x86_64" \
-DCMAKE_OSX_DEPLOYMENT_TARGET=${{ matrix.min-osx-target }} \
-DQT_MAC_TEAM_ID=${{ secrets.MAC_TEAM_ID }} \
-DQT_MAC_CODE_SIGN_IDENTITY="Developer ID Application" \
-DQT_MAC_PROVISIONING_PROFILE_SPECIFIER=com.qaterialgallery.naostage.mac.devidapplication \
-B ./build/ -S .
-
name: 🔨 Build QaterialGallery
run: cmake --build build --target QaterialGallery --config "${{ matrix.build-type }}"
-
name: 🚀 Deploy QaterialGallery Dmg
run: cmake --build build --target QaterialGalleryDmg --config "${{ matrix.build-type }}"
-
name: 📦 Upload QaterialGallery Dmg
uses: actions/upload-artifact@v2
with:
name: QaterialGallery-${{ matrix.min-osx-target }}.dmg
path: build/${{ matrix.build-type }}/QaterialGallery.dmg
-
name: 🚀 Upload Release Asset
if: github.event_name == 'release' && startsWith(github.ref, 'refs/tags/v')
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
asset_path: build/${{ matrix.build-type }}/QaterialGallery.dmg
asset_name: QaterialGallery-${{ matrix.min-osx-target }}.dmg
asset_content_type: application/zip