github: switch PR workflow from an allowlist to a blocklist
This is going to be less work to maintain going forward since we won't need to change it every time we include a new subproject. Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
parent
cf03c55478
commit
9dc56214b9
1 changed files with 3 additions and 3 deletions
6
.github/workflows/pull_request.yml
vendored
6
.github/workflows/pull_request.yml
vendored
|
@ -21,9 +21,9 @@ jobs:
|
|||
pull_number: context.payload.number,
|
||||
per_page: 100
|
||||
})
|
||||
const serviceChanged = result.data.filter(f => f.filename.startsWith("app/") || f.filename.startsWith("buildSrc/") || f.filename.endsWith("gradle") || f.filename.startsWith(".github/workflows/pull_request.yml") || f.filename.startsWith("gradle") || f.filename.endsWith("properties")).length > 0
|
||||
console.log(serviceChanged)
|
||||
return serviceChanged
|
||||
const shouldRun = result.data.filter(f => !f.filename.endsWith(".md") || !f.filename.endsWith(".txt") || !f.filename.startsWith("contrib/") || !f.filename.endsWith(".yml")).length > 0
|
||||
console.log(shouldRun)
|
||||
return shouldRun
|
||||
|
||||
- name: Checkout repository
|
||||
if: ${{ steps.service-changed.outputs.result == 'true' }}
|
||||
|
|
Loading…
Reference in a new issue