Skip to content

Commit

Permalink
chore: add PR step for validating iOS builds
Browse files Browse the repository at this point in the history
  • Loading branch information
moldy530 authored and graphite-app[bot] committed Jan 7, 2025
1 parent f9e3e91 commit b7af15e
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 13 deletions.
15 changes: 15 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,21 @@ runs:
run: |
/bin/bash -c "yes | $ANDROID_HOME/cmdline-tools/latest/bin/sdkmanager --licenses > /dev/null"
- name: Clear Linux specific files
if: runner.os == 'Linux'
shell: bash
run: |
sudo swapoff -a
sudo rm -f /swapfile
sudo apt clean
images=$(docker image ls -aq)
if [ -n "$images" ]; then
docker rmi $images
else
echo "No images to remove."
fi
df -h
# similarly, I'm not seeing this cache ever get used
# - name: Cache Gradle
# if: env.turbo_cache_hit != 1
Expand Down
44 changes: 31 additions & 13 deletions .github/workflows/on-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,19 +75,6 @@ jobs:
fetch-depth: "0"
submodules: "recursive"

- name: free disk space
run: |
sudo swapoff -a
sudo rm -f /swapfile
sudo apt clean
images=$(docker image ls -aq)
if [ -n "$images" ]; then
docker rmi $images
else
echo "No images to remove."
fi
df -h
- name: Setup
uses: ./.github/actions/setup

Expand All @@ -114,4 +101,35 @@ jobs:

- name: Unit Test
run: yarn test:ci

build_ios:
name: Build iOS
runs-on: macos-14
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
API_KEY: ${{ secrets.API_KEY }}
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ vars.TURBO_TEAM }}
steps:
- name: "Checkout files"
uses: actions/checkout@v3
with:
token: ${{ secrets.ALCHEMY_BOT_PAT }}
fetch-depth: "0"
submodules: "recursive"

- name: Setup
uses: ./.github/actions/setup

- name: Install cocoapods
if: env.turbo_cache_hit != 1 && steps.cocoapods-cache.outputs.cache-hit != 'true'
run: |
cd example/ios
pod install
env:
NO_FLIPPER: 1

- name: Build example for iOS
working-directory: account-kit/rn-signer/example
run: |
yarn turbo run build:ios

0 comments on commit b7af15e

Please sign in to comment.