shared-swift.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. name: shared-swift
  2. on:
  3. workflow_dispatch:
  4. pull_request:
  5. paths:
  6. - 'FirebaseSharedSwift**'
  7. - '.github/workflows/shared-swift.yml'
  8. - 'Gemfile*'
  9. schedule:
  10. # Run every day at 3am (PST) - cron uses UTC times
  11. - cron: '0 11 * * *'
  12. concurrency:
  13. group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
  14. cancel-in-progress: true
  15. jobs:
  16. spm:
  17. uses: ./.github/workflows/common.yml
  18. with:
  19. target: FirebaseSharedSwiftTests
  20. pod-lib-lint:
  21. # Don't run on private repo unless it is a PR.
  22. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  23. strategy:
  24. matrix:
  25. target: [ios, tvos, macos, watchos]
  26. build-env:
  27. - os: macos-14
  28. xcode: Xcode_16.2
  29. swift_version: 5.9
  30. - os: macos-15
  31. xcode: Xcode_16.2
  32. swift_version: 5.9
  33. - os: macos-15
  34. xcode: Xcode_16.3
  35. swift_version: 6.0
  36. runs-on: ${{ matrix.build-env.os }}
  37. steps:
  38. - uses: actions/checkout@v4
  39. - uses: ruby/setup-ruby@354a1ad156761f5ee2b7b13fa8e09943a5e8d252 # v1
  40. - name: Setup Bundler
  41. run: scripts/setup_bundler.sh
  42. - name: Xcode
  43. run: sudo xcode-select -s /Applications/${{ matrix.build-env.xcode }}.app/Contents/Developer
  44. - name: Set Swift swift_version
  45. run: sed -i "" "s/s.swift_version[[:space:]]*=[[:space:]]*'5.9'/s.swift_version = '${{ matrix.build-env.swift_version }}'/" FirebaseSharedSwift.podspec
  46. - name: Build and test
  47. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseSharedSwift.podspec --platforms=${{ matrix.target }}