Skip to content

Commit

Permalink
Merge pull request #204 from 10up/enhancement/203
Browse files Browse the repository at this point in the history
Added paths filter to GitHub actions
  • Loading branch information
jeffpaul authored Dec 8, 2022
2 parents 1214986 + f123dc3 commit 6e34054
Show file tree
Hide file tree
Showing 8 changed files with 58 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/cypress.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ on:
pull_request:
branches:
- develop
paths:
- '**.js'
- '**.php'
- '**.css'

jobs:
cypress:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
pull_request:
branches:
- develop
paths: # Note: Update paths here will also require updating paths in ignore.eslint.yml.
- '**.js'

jobs:
eslint:
Expand Down
14 changes: 14 additions & 0 deletions .github/workflows/ignore-eslint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: ESLint

on:
pull_request:
branches:
- develop
paths-ignore:
- '**.js'

jobs:
eslint:
runs-on: ubuntu-latest
steps:
- run: 'echo "No ESLint check required"'
14 changes: 14 additions & 0 deletions .github/workflows/ignore-phpcs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: PHPCS

on:
pull_request:
branches:
- develop
paths-ignore:
- '**.php'

jobs:
phpcs:
runs-on: ubuntu-latest
steps:
- run: 'echo "No PHPCS check required"'
18 changes: 18 additions & 0 deletions .github/workflows/ignore-phpunit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: PHPUnit

on:
pull_request:
branches:
- develop
paths-ignore:
- '**.php'

jobs:
phpunit:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php-versions: ['7.4', '8.0']
steps:
- run: 'echo "No PHPUnit check required"'
2 changes: 2 additions & 0 deletions .github/workflows/php-compatibility.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
pull_request:
branches:
- develop
paths:
- '**.php'

jobs:
php_compatibility:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/phpcs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
pull_request:
branches:
- develop
paths: # Note: Update paths here will also require updating paths in ignore.phpcs.yml.
- '**.php'

jobs:
phpcs:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/phpunit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ on:
pull_request:
branches:
- develop
paths: # Note: Update paths here will also require updating paths in ignore.phpunit.yml.
- '**.php'

jobs:
phpunit:
Expand Down

0 comments on commit 6e34054

Please sign in to comment.