dynamiclinks.yml 4.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495
  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 3am (PST) - cron uses UTC times
  11. - cron: '0 11 * * *'
  12. jobs:
  13. pod_lib_lint:
  14. # Don't run on private repo unless it is a PR.
  15. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  16. runs-on: macos-11
  17. steps:
  18. - uses: actions/checkout@v2
  19. - name: Setup Bundler
  20. run: scripts/setup_bundler.sh
  21. - name: FirebaseDynamicLinks
  22. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseDynamicLinks.podspec
  23. spm:
  24. # Don't run on private repo unless it is a PR.
  25. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  26. runs-on: macos-11
  27. steps:
  28. - uses: actions/checkout@v2
  29. - uses: mikehardy/buildcache-action@50738c6c77de7f34e66b870e4f8ede333b69d077
  30. with:
  31. cache_key: ${{ matrix.os }}
  32. - name: Initialize xcodebuild
  33. run: scripts/setup_spm_tests.sh
  34. - name: iOS Unit Tests
  35. run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseDynamicLinks iOS spmbuildonly
  36. dynamiclinks-cron-only:
  37. # Don't run on private repo.
  38. if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
  39. runs-on: macos-11
  40. strategy:
  41. matrix:
  42. flags: [
  43. '--use-static-frameworks',
  44. '--use-libraries'
  45. ]
  46. needs: pod_lib_lint
  47. steps:
  48. - uses: actions/checkout@v2
  49. - name: Setup Bundler
  50. run: scripts/setup_bundler.sh
  51. - name: PodLibLint Storage Cron
  52. run: scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseDynamicLinks.podspec --platforms=ios ${{ matrix.flags }}
  53. quickstart:
  54. # Don't run on private repo unless it is a PR.
  55. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  56. env:
  57. plist_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  58. signin_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  59. runs-on: macos-11
  60. steps:
  61. - uses: actions/checkout@v2
  62. - name: Setup quickstart
  63. run: scripts/setup_quickstart.sh DynamicLinks
  64. - name: Install Secret GoogleService-Info.plist
  65. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/qs-dynamiclinks.plist.gpg \
  66. quickstart-ios/dynamiclinks/GoogleService-Info.plist "$plist_secret"
  67. - name: Update Environment Variable For DynamicLinks
  68. run: |
  69. sed -i '' 's#DYNAMIC_LINK_DOMAIN#https://qpf6m.app.goo.gl#' quickstart-ios/dynamiclinks/DynamicLinksExample/DynamicLinksExample.entitlements
  70. sed -i '' 's#YOUR_DOMAIN_URI_PREFIX";#https://qpf6m.app.goo.gl";#' quickstart-ios/dynamiclinks/DynamicLinksExample/ViewController.m
  71. sed -i '' 's#YOUR_DOMAIN_URI_PREFIX";#https://qpf6m.app.goo.gl";#' quickstart-ios/dynamiclinks/DynamicLinksExampleSwift/ViewController.swift
  72. - name: Test objc quickstart
  73. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh DynamicLinks true)
  74. - name: Test swift quickstart
  75. if: ${{ always() }}
  76. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh DynamicLinks true swift)
  77. podspec-presubmit:
  78. # Don't run on private repo unless it is a PR.
  79. if: github.repository == 'Firebase/firebase-ios-sdk' && github.event.pull_request.merged != true && github.event.action != 'closed'
  80. runs-on: macos-11
  81. steps:
  82. - uses: actions/checkout@v2
  83. - name: Setup Bundler
  84. run: scripts/setup_bundler.sh
  85. - name: Build and test
  86. run: scripts/third_party/travis/retry.sh pod spec lint FirebaseDynamicLinks.podspec --skip-tests --sources='https://github.com/firebase/SpecsTesting','https://github.com/firebase/SpecsDev.git','https://github.com/firebase/SpecsStaging.git','https://cdn.cocoapods.org/'