Merge pull request #168 from luke-h1/feat/chat-improvs #2
This file contains 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 iOS Debug App | |
on: | |
push: | |
branches: | |
- main # Build on main for caching purposes, this way every branch will have access to it | |
workflow_call: | |
outputs: | |
build-cache-key: | |
description: 'The primary key used for caching the build' | |
value: ios-debug-build-${{ jobs.lookup-cached-build.outputs.fingerprint }} | |
jobs: | |
lookup-cached-build: | |
name: Lookup cached debug build | |
uses: ./.github/workflows/lookup-cached-debug-build.yml | |
with: | |
platform: ios | |
build-debug-ios: | |
name: Build iOS Debug App | |
needs: lookup-cached-build | |
if: needs.lookup-cached-build.outputs.build-exists != 'true' | |
runs-on: macos-latest | |
steps: | |
- name: 🏗 Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
ref: ${{ github.head_ref }} | |
- name: 🥟 Setup Bun | |
uses: oven-sh/setup-bun@v2 | |
with: | |
bun-version-file: '.bun-version' | |
- name: 🔨 Use latest stable Xcode | |
uses: maxim-lobanov/setup-xcode@v1 | |
with: | |
xcode-version: latest-stable | |
- name: 📦 Install dependencies | |
run: bun install --frozen-lockfile | |
- name: Setup Node | |
uses: actions/[email protected] | |
with: | |
node-version-file: .nvmrc | |
- name: 🛠️ Build | |
run: bun run build:debug:ios | |
- name: 📁 Prepare cache folder | |
run: | | |
mkdir ios-debug-build | |
mv ./ios/build/Build/Products/Debug-iphonesimulator/Foam.app ios-debug-build/ios-debug.app | |
- name: 📡 Store built app in cache | |
id: ios-debug-save | |
uses: actions/cache/save@v4 | |
with: | |
path: ios-debug-build/ | |
key: ios-debug-build-${{ needs.lookup-cached-build.outputs.fingerprint }} |