dynamiclinks.yml 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. name: dynamiclinks
  2. on:
  3. pull_request:
  4. paths:
  5. - 'FirebaseDynamicLinks**'
  6. - '.github/workflows/dynamiclinks.yml'
  7. - 'Interop/Analytics/Public/*.h'
  8. - 'Gemfile*'
  9. schedule:
  10. # Run every day at 1am (PST) - cron uses UTC times
  11. - cron: '0 9 * * *'
  12. concurrency:
  13. group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
  14. cancel-in-progress: true
  15. jobs:
  16. pod_lib_lint:
  17. # Don't run on private repo unless it is a PR.
  18. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  19. runs-on: macos-11
  20. steps:
  21. - uses: actions/checkout@v2
  22. - name: Setup Bundler
  23. run: scripts/setup_bundler.sh
  24. - name: FirebaseDynamicLinks
  25. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseDynamicLinks.podspec
  26. spm:
  27. # Don't run on private repo unless it is a PR.
  28. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  29. runs-on: macos-11
  30. steps:
  31. - uses: actions/checkout@v2
  32. - uses: mikehardy/buildcache-action@50738c6c77de7f34e66b870e4f8ede333b69d077
  33. with:
  34. cache_key: ${{ matrix.os }}
  35. - name: Initialize xcodebuild
  36. run: scripts/setup_spm_tests.sh
  37. - name: iOS Unit Tests
  38. run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseDynamicLinks iOS spmbuildonly
  39. dynamiclinks-cron-only:
  40. # Don't run on private repo.
  41. if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
  42. runs-on: macos-11
  43. strategy:
  44. matrix:
  45. flags: [
  46. '--use-static-frameworks'
  47. ]
  48. needs: pod_lib_lint
  49. steps:
  50. - uses: actions/checkout@v2
  51. - name: Setup Bundler
  52. run: scripts/setup_bundler.sh
  53. - name: PodLibLint Storage Cron
  54. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseDynamicLinks.podspec --platforms=ios ${{ matrix.flags }}
  55. quickstart:
  56. # Don't run on private repo unless it is a PR.
  57. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  58. env:
  59. plist_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  60. signin_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  61. runs-on: macos-11
  62. steps:
  63. - uses: actions/checkout@v2
  64. - name: Setup quickstart
  65. run: scripts/setup_quickstart.sh DynamicLinks
  66. - name: Install Secret GoogleService-Info.plist
  67. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/qs-dynamiclinks.plist.gpg \
  68. quickstart-ios/dynamiclinks/GoogleService-Info.plist "$plist_secret"
  69. - name: Update Environment Variable For DynamicLinks
  70. run: |
  71. sed -i '' 's#DYNAMIC_LINK_DOMAIN#https://qpf6m.app.goo.gl#' quickstart-ios/dynamiclinks/DynamicLinksExample/DynamicLinksExample.entitlements
  72. sed -i '' 's#YOUR_DOMAIN_URI_PREFIX";#https://qpf6m.app.goo.gl";#' quickstart-ios/dynamiclinks/DynamicLinksExample/ViewController.m
  73. sed -i '' 's#YOUR_DOMAIN_URI_PREFIX";#https://qpf6m.app.goo.gl";#' quickstart-ios/dynamiclinks/DynamicLinksExampleSwift/ViewController.swift
  74. - name: Test objc quickstart
  75. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh DynamicLinks true)
  76. - name: Test swift quickstart
  77. if: ${{ always() }}
  78. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh DynamicLinks true swift)