check.yml 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. name: check
  2. on:
  3. pull_request:
  4. paths-ignore:
  5. - 'Firestore/**'
  6. push:
  7. branches: main
  8. concurrency:
  9. group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
  10. cancel-in-progress: true
  11. jobs:
  12. check:
  13. # Don't run on private repo.
  14. if: github.repository == 'Firebase/firebase-ios-sdk'
  15. runs-on: ubuntu-latest
  16. env:
  17. MINT_PATH: ${{ github.workspace }}/mint
  18. steps:
  19. - uses: actions/checkout@v4
  20. - uses: actions/setup-python@v5
  21. with:
  22. python-version: 3.11
  23. - name: Cache Mint packages
  24. uses: actions/cache@v4
  25. with:
  26. path: ${{ env.MINT_PATH }}
  27. key: ${{ runner.os }}-mint-${{ hashFiles('**/Mintfile') }}
  28. restore-keys: ${{ runner.os }}-mint-
  29. - name: Setup check
  30. run: |
  31. eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
  32. scripts/setup_check.sh
  33. - name: Check
  34. run: |
  35. eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
  36. # Add Homebrew clang-format to first in PATH
  37. export PATH="/home/linuxbrew/.linuxbrew/opt/clang-format/bin:$PATH"
  38. scripts/check.sh --test-only