Skip to content

Add Google Gemini LLM options #48

Add Google Gemini LLM options

Add Google Gemini LLM options #48

Workflow file for this run

name: Open Sesame iOS
on:
push:
branches:
- main
pull_request:
branches:
- "**"
paths-ignore:
- "**/README.md"
- "client/android/**"
- "client/cmdline/**"
- "client/sandbox/**"
- "client/web/**"
- "database/**"
- "scripts/**"
- "server/**"
- "sesame/**"
env:
CARGO_TERM_COLOR: always
concurrency:
group: build-ios-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
build-daily-ios-assistant:
name: Build, Analyze & Test daily-ios-assistant [${{ matrix.destination }}]
runs-on: [self-hosted, macOS, stableMacOS]
strategy:
matrix:
destination:
- "generic/platform=iOS"
- "platform=iOS Simulator,OS=17.2,name=iPhone 15"
steps:
- name: Checkout repo
uses: actions/checkout@v4
with:
submodules: recursive
token: ${{ secrets.DAILY_AUTOBOT_GITHUB_PAT }}
- name: Install pod dependencies
working-directory: ./client/ios
run: |
pod install
- name: Set up Xcode
working-directory: ./client/ios
run: |
xcodebuild -resolvePackageDependencies
- name: Show available destinations
working-directory: ./client/ios
run: set -o pipefail && xcodebuild -scheme 'OpenSesame' -workspace './OpenSesame.xcworkspace' -showdestinations | xcbeautify
- name: Build daily-ios-assistant
working-directory: ./client/ios
run: set -o pipefail && security unlock-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" "${{ secrets.KEYCHAIN_NAME }}" && xcodebuild clean build -workspace './OpenSesame.xcworkspace' -scheme 'OpenSesame' -destination '${{ matrix.destination }}' -showBuildTimingSummary -allowProvisioningUpdates | tee ./xcodebuild.log | xcbeautify
- name: Run `swiftlint analyze` on 'OpenSesame' app
working-directory: ./client/ios
run: swiftlint analyze --config "./.swiftlint.yml" --reporter "xcode" --compiler-log-path ./xcodebuild.log ./
- uses: jwalton/gh-find-current-pr@v1
id: get_pr_number
with:
# Can be "open", "closed", or "all". Defaults to "open".
state: open
- name: Build daily-ios-assistant-demo archive
working-directory: ./client/ios
# only want to run this once per build
if: matrix.destination == 'generic/platform=iOS'
run: set -o pipefail && security unlock-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" "${{ secrets.KEYCHAIN_NAME }}" && xcodebuild -workspace './OpenSesame.xcworkspace' -scheme 'OpenSesame' -destination '${{ matrix.destination }}' -archivePath ./out/OpenSesame archive -allowProvisioningUpdates
- name: emit apple key file
working-directory: ./client/ios
if: matrix.destination == 'generic/platform=iOS'
run: |
mkdir -p ./private_keys/
echo "${{ secrets.APPLE_AUTHENTICATION_KEY }}" | base64 -D > ./private_keys/AuthKey_${{ secrets.APPLE_AUTHENTICATION_KEY_ID }}.p8
- name: Update version number in xcarchive
working-directory: ./client/ios
# only want to run this once per build
if: matrix.destination == 'generic/platform=iOS'
env:
# GH_PR_NUMBER is used in an XCode Build Phase step we added, "Set Version Number",
# to decide between 1.0.0 (a mainline build) or 0.0.pr_number (a pull request build).
# The build number should auto-increment for new builds of a given version.
GH_PR_NUMBER: ${{ steps.get_pr_number.outputs.number }}
run: |
./scripts/set_xcarchive_version.sh ./out/OpenSesame.xcarchive $GH_PR_NUMBER
- name: Upload OpenSesame.xcarchive
uses: actions/upload-artifact@v4
if: matrix.destination == 'generic/platform=iOS'
with:
name: OpenSesame.xcarchive
path: |
./client/ios/out/OpenSesame.xcarchive
- name: Build and upload daily-ios-assistant-demo IPA
working-directory: ./client/ios
# only want to run this once per build
if: matrix.destination == 'generic/platform=iOS'
env:
# GH_PR_NUMBER is used in an XCode Build Phase step we added, "Set Version Number",
# to decide between 1.0.0 (a mainline build) or 0.0.pr_number (a pull request build).
# The build number should auto-increment for new builds of a given version.
GH_PR_NUMBER: ${{ steps.get_pr_number.outputs.number }}
run: |
set -o pipefail && security unlock-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" "${{ secrets.KEYCHAIN_NAME }}"
./scripts/build_app.sh . OpenSesame OpenSesame.ipa ${{ secrets.APPLE_AUTHENTICATION_KEY_ID }} ${{ secrets.APPLE_AUTHENTICATION_KEY_ISSUER_ID }} $GH_PR_NUMBER
xcrun altool --upload-app -f ./out/OpenSesame.ipa -t ios --apiKey ${{ secrets.APPLE_AUTHENTICATION_KEY_ID }} --apiIssuer ${{ secrets.APPLE_AUTHENTICATION_KEY_ISSUER_ID }}
- name: remove apple key file
working-directory: ./client/ios
if: success() || failure()
run: rm -rf ./private_keys/AuthKey_${{ secrets.APPLE_AUTHENTICATION_KEY_ID }}.p8