Skip to content

workflow (flutter): removed ccache & caching derived-data #35

workflow (flutter): removed ccache & caching derived-data

workflow (flutter): removed ccache & caching derived-data #35

name: Create an iOS Simulator build
on:
push:
paths:
- '*'
- '.github/workflows/build-ios-simulator.yml'
- 'lib/**'
- 'ios/**'
- '!**/*.md'
branches:
- flutter
jobs:
build-ios-simulator:
name: Create an iOS Simulator build
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
# Setup the flutter environment.
- name: Setup Flutter environment
uses: subosito/flutter-action@v2
with:
cache: true
- name: Restore Pods cache
uses: actions/cache@v4
with:
path: |
ios/Pods
~/Library/Caches/CocoaPods
~/.cocoapods
key: ${{ runner.os }}-pods-${{ hashFiles('ios/Podfile.lock') }}
restore-keys: ${{ runner.os }}-pods-
- name: Restore build artifacts from cache
uses: actions/cache@v4
with:
path: build/ios
key: ${{ runner.os }}-ios-derived-data-${{ hashFiles('ios/Podfile.lock') }}
restore-keys: ${{ runner.os }}-ios-derived-data-
- name: Build iOS ipa
run: flutter build ios --simulator --no-codesign --obfuscate --split-debug-info --config-only
- name: Store build .app file as zip
run: |
cd build/ios/iphonesimulator
mv Runner.app flutter_github_actions.app
mkdir -p output
zip -r -y -o output/flutter_github_actions.zip flutter_github_actions.app
- name: Save build file as artifact
uses: actions/upload-artifact@v4
with:
name: flutter_github_actions
path: build/ios/iphonesimulator/output