ci: fix TPU skip if (#17672)
This commit is contained in:
parent
1307b605e8
commit
e314d3a772
|
@ -5,6 +5,7 @@ on:
|
|||
branches: [master, "release/*"]
|
||||
pull_request_target:
|
||||
branches: [master, "release/*"]
|
||||
types: [ opened, reopened, edited, ready_for_review, synchronize ]
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref }}
|
||||
|
@ -25,8 +26,11 @@ env:
|
|||
jobs:
|
||||
test-on-tpus:
|
||||
runs-on: ubuntu-22.04
|
||||
# run only when the PR title contains '[TPU]' or is a merge to master
|
||||
if: ${{ startsWith(github.event_name, 'pull_request') && contains(github.event.pull_request.title, '[TPU]') || (github.event_name == 'push' && github.ref == 'refs/heads/master') }}
|
||||
# run only when the PR title contains 'TPU' or is a merge to master
|
||||
if: |
|
||||
(github.event_name == 'push' && github.ref == 'refs/heads/master') ||
|
||||
(startsWith(github.event_name, 'pull_request') && ( contains(github.event.pull_request.title, 'TPU'))
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
|
|
Loading…
Reference in New Issue