Build Samples #61
This file contains hidden or 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
| # Copyright 2025 Google LLC | |
| # | |
| # Licensed under the Apache License, Version 2.0 (the "License"); | |
| # you may not use this file except in compliance with the License. | |
| # You may obtain a copy of the License at | |
| # | |
| # http://www.apache.org/licenses/LICENSE-2.0 | |
| # | |
| # Unless required by applicable law or agreed to in writing, software | |
| # distributed under the License is distributed on an "AS IS" BASIS, | |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
| # See the License for the specific language governing permissions and | |
| # limitations under the License. | |
| name: Build Samples | |
| on: | |
| push: | |
| branches: [ '*' ] | |
| pull_request: | |
| branches: [ '*' ] | |
| repository_dispatch: | |
| types: [ build ] | |
| schedule: | |
| - cron: '0 22 * * *' | |
| workflow_dispatch: | |
| jobs: | |
| build-GoogleNavigationDemos: | |
| runs-on: macos-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install CocoaPods | |
| run: | | |
| sudo gem install cocoapods | |
| - name: Run pod install | |
| run: | | |
| pod install --project-directory=GoogleNavigation/ | |
| - name: Build project | |
| run: | | |
| echo "Replacing #error for API key" | |
| sed -i .prev '/#error/'d GoogleNavigation/GoogleNavSwiftXCFrameworkDemos/Swift/SDKDemoAPIKey.swift | |
| echo "Building" | |
| xcodebuild -workspace GoogleNavigation/GoogleNavSwiftXCFrameworkDemos.xcworkspace \ | |
| -scheme GoogleNavSwiftXCFrameworkDemos \ | |
| -destination 'platform=iOS Simulator,OS=17.4,name=iPhone 15' build | xcpretty | |
| test: # used as required status check | |
| runs-on: ubuntu-latest | |
| needs: | |
| - build-GoogleNavigationDemos | |
| steps: | |
| - run: echo "Fail if all other steps are not successful" |