subsurface/.github/workflows/ios.yml.disabled
Michael Keller 015ac0e459 CICD: Build Release Versions on Push.
Change the builds on push (i.e. pull request merges) to build release
versions. This seems to be the correct way to build these, as they are
now distributed as the official builds on
https://subsurface-divelog.org/.
For users wanting to help with debugging, build artifacts on pull
requests are available, and these are debug builds.
Also adding the option to manually trigger builds, so if needed debug
builds can be run on `master`.

Signed-off-by: Michael Keller <github@ike.ch>
2024-11-26 19:37:45 +13:00

68 lines
1.9 KiB
Text

name: iOS
on:
push:
paths-ignore:
- scripts/docker/**
branches:
- master
pull_request:
paths-ignore:
- scripts/docker/**
branches:
- master
workflow_dispatch:
jobs:
build:
runs-on: macOS-12
steps:
- name: switch to Xcode 13
run: sudo xcode-select -s "/Applications/Xcode_13.1.app"
- name: checkout sources
uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: recursive
- name: setup Homebrew
run: brew install automake
- name: checkout Qt resources
uses: actions/checkout@v4
with:
repository: subsurface/qt-ios
ref: main
path: qt-ios
- name: set the version information
id: version_number
uses: ./.github/actions/manage-version
with:
nightly-builds-secret: ${{ secrets.NIGHTLY_BUILDS }}
- name: build Subsurface-mobile for iOS
env:
VERSION: ${{ steps.version_number.outputs.version }}
run: |
BUILD_EXTRA_ARGS=""
if [ "${GITHUB_EVENT_NAME}" = "push" ]; then
echo "Building a release version"
BUILD_EXTRA_ARGS="${BUILD_EXTRA_ARGS} -release"
fi
cd ..
git config --global --add safe.directory $GITHUB_WORKSPACE
git config --global --add safe.directory $GITHUB_WORKSPACE/libdivecomputer
export IOS_QT=$GITHUB_WORKSPACE/qt-ios
echo "build for simulator"
bash -x $GITHUB_WORKSPACE/packaging/ios/build.sh -simulator ${BUILD_EXTRA_ARGS}
# We need this in order to be able to access the file and publish it
mv build-Subsurface-mobile-Qt_5_14_1_for_iOS-Release/Release-iphonesimulator/Subsurface-mobile.app $GITHUB_WORKSPACE/Subsurface-mobile-$VERSION.app
- name: publish artifacts
uses: actions/upload-artifact@v4
with:
name: Subsurface-iOS-${{ steps.version_number.outputs.version }}
path: Subsurface-mobile-*.app