diff --git a/.github/workflows/coding-standards.yml b/.github/workflows/coding-standards.yml index 8f1e9fe701330..e1526d54913f3 100644 --- a/.github/workflows/coding-standards.yml +++ b/.github/workflows/coding-standards.yml @@ -14,20 +14,60 @@ on: - '3.[89]' - '[4-9].[0-9]' paths: - # Any change to a PHP or JavaScript file should run checks. - - '**.js' - - '**.php' - # These files configure npm. Changes could affect the outcome. + - '**' + # Documentation, repository metadata, and local environment configuration. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.env.example' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!docker-compose.yml' + - '!jsdoc.conf.json' + - '!tsconfig.json' + - '!typings/**' + - '!wp-cli.yml' + # File types that PHPCS and JSHint do not inspect. + - '!**.crt' + - '!**.css' + - '!**.dat' + - '!**.dist' + - '!**.html' + - '!**.jpg' + - '!**.json' + - '!**.map' + - '!**.mo' + - '!**.neon' + - '!**.pem' + - '!**.png' + - '!**.po' + - '!**.scss' + - '!**.svg' + - '!**.txt' + - '!**.webp' + - '!**.woff2' + - '!**.xml' + - '!**.yaml' + - '!**.yml' + # JavaScript outside the JSHint targets and all tooling are not inspected. + - '!tests/e2e/**.js' + - '!tests/performance/**.js' + - '!tools/**' + - '!.eslintrc-jsdoc.js' + - '!.prettierrc.js' + - '!eslint.config.js' + - '!webpack.config.js' + # Other workflows do not affect these checks. + - '!.github/**' + # Re-include configuration and workflow files that affect these checks. - 'package*.json' - '.npmrc' - '.nvmrc' - # These files configure Composer. Changes could affect the outcome. + - 'Gruntfile.js' - 'composer.*' - # This file configures JSHint. Changes could affect the outcome. - - '.jshintrc' - # This file configures PHPCS. Changes could affect the outcome. + - '**.jshintrc' - 'phpcs.xml.dist' - # Confirm any changes to relevant workflow files. - '.github/workflows/coding-standards.yml' - '.github/workflows/reusable-coding-standards-*.yml' workflow_dispatch: diff --git a/.github/workflows/end-to-end-tests.yml b/.github/workflows/end-to-end-tests.yml index d91b6512f4b49..5c63cde47a349 100644 --- a/.github/workflows/end-to-end-tests.yml +++ b/.github/workflows/end-to-end-tests.yml @@ -13,24 +13,37 @@ on: - '5.[3-9]' - '[6-9].[0-9]' paths: - # Any change to a PHP, CSS, or JavaScript file should run checks. - - '**.css' - - '**.js' - - '**.php' - # These files configure npm and the task runner. Changes could affect the outcome. - - 'package*.json' - - '.npmrc' - - '.nvmrc' - - 'Gruntfile.js' - - 'webpack.config.js' + - '**' + # Documentation and repository metadata. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!typings/**' + # Configuration for unrelated checks. + - '!.eslintrc-jsdoc.js' + - '!.jshintrc' + - '!.prettierrc.js' + - '!.version-support-*.json' + - '!eslint.config.js' + - '!jsdoc.conf.json' + - '!phpcompat.xml.dist' + - '!phpcs.xml.dist' + - '!phpstan.neon.dist' + - '!phpunit.xml.dist' + - '!tsconfig.json' + # Other test suites, tools, and workflows do not affect these tests. + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include the test, tool, and workflow files used here. + - 'tests/e2e/**' - 'tools/gutenberg/**' + - 'tools/local-env/**' - 'tools/vendors/**' - 'tools/webpack/**' - # These files configure Composer. Changes could affect the outcome. - - 'composer.*' - # This files affect the e2e tests. Changes could affect the outcome. - - 'tests/e2e/**' - # Confirm any changes to relevant workflow files. - '.github/workflows/end-to-end-tests.yml' - '.github/workflows/reusable-end-to-end-tests*.yml' workflow_dispatch: diff --git a/.github/workflows/javascript-tests.yml b/.github/workflows/javascript-tests.yml index 8b1241038773d..ed38f79aa709b 100644 --- a/.github/workflows/javascript-tests.yml +++ b/.github/workflows/javascript-tests.yml @@ -13,9 +13,52 @@ on: - '3.[89]' - '[4-9].[0-9]' paths: - # Any change to a JavaScript file should run tests. - - '**.js' - # These files configure npm and the task runner. Changes could affect the outcome. + - '**' + # Documentation, repository metadata, and local environment configuration. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.env.example' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!docker-compose.yml' + - '!jsdoc.conf.json' + - '!typings/**' + - '!wp-cli.yml' + # File types that the JavaScript tests do not exercise. + - '!**.crt' + - '!**.css' + - '!**.dat' + - '!**.dist' + - '!**.html' + - '!**.jpg' + - '!**.json' + - '!**.map' + - '!**.mo' + - '!**.neon' + - '!**.pem' + - '!**.php' + - '!**.png' + - '!**.po' + - '!**.scss' + - '!**.svg' + - '!**.txt' + - '!**.webp' + - '!**.woff2' + - '!**.xml' + - '!**.yaml' + - '!**.yml' + # JavaScript outside the QUnit suite and related tooling is not exercised. + - '!tests/e2e/**.js' + - '!tests/performance/**.js' + - '!tools/**' + - '!.eslintrc-jsdoc.js' + - '!.prettierrc.js' + - '!eslint.config.js' + # Other workflows do not affect these tests. + - '!.github/**' + # Re-include configuration, tests, tools, and workflows used here. - 'package*.json' - '.npmrc' - '.nvmrc' @@ -24,13 +67,9 @@ on: - 'tools/gutenberg/**' - 'tools/vendors/**' - 'tools/webpack/**' - # This file configures ESLint. Changes could affect the outcome. - '.eslintignore' - # This file configures JSHint. Changes could affect the outcome. - '.jshintrc' - # Any change to the QUnit directory should run tests. - 'tests/qunit/**' - # Confirm any changes to relevant workflow files. - '.github/workflows/javascript-tests.yml' - '.github/workflows/reusable-javascript-tests.yml' workflow_dispatch: diff --git a/.github/workflows/local-docker-environment.yml b/.github/workflows/local-docker-environment.yml index 856db171726b6..894aeeebd779c 100644 --- a/.github/workflows/local-docker-environment.yml +++ b/.github/workflows/local-docker-environment.yml @@ -13,6 +13,7 @@ on: - 'docker-compose.yml' # Any changes to local environment related files - 'tools/local-env/**' + - 'wp-cli.yml' # These files configure npm and the task runner. Changes could affect the outcome. - 'package*.json' - 'Gruntfile.js' @@ -41,6 +42,7 @@ on: - 'docker-compose.yml' # Any changes to local environment related files - 'tools/local-env/**' + - 'wp-cli.yml' # These files configure npm and the task runner. Changes could affect the outcome. - 'package*.json' - 'Gruntfile.js' diff --git a/.github/workflows/performance.yml b/.github/workflows/performance.yml index ef02c51101557..f8f4c146ee38b 100644 --- a/.github/workflows/performance.yml +++ b/.github/workflows/performance.yml @@ -13,24 +13,37 @@ on: - '6.[2-9]' - '[7-9].[0-9]' paths: - # Any change to a PHP, CSS, or JavaScript file should run checks. - - '**.css' - - '**.js' - - '**.php' - # These files configure npm and the task runner. Changes could affect the outcome. - - 'package*.json' - - '.npmrc' - - '.nvmrc' - - 'Gruntfile.js' - - 'webpack.config.js' + - '**' + # Documentation and repository metadata. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!typings/**' + # Configuration for unrelated checks. + - '!.eslintrc-jsdoc.js' + - '!.jshintrc' + - '!.prettierrc.js' + - '!.version-support-*.json' + - '!eslint.config.js' + - '!jsdoc.conf.json' + - '!phpcompat.xml.dist' + - '!phpcs.xml.dist' + - '!phpstan.neon.dist' + - '!phpunit.xml.dist' + - '!tsconfig.json' + # Other test suites, tools, and workflows do not affect these tests. + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include the test, tool, and workflow files used here. + - 'tests/performance/**' - 'tools/gutenberg/**' + - 'tools/local-env/**' - 'tools/vendors/**' - 'tools/webpack/**' - # These files configure Composer. Changes could affect the outcome. - - 'composer.*' - # This files affect the performance tests. Changes could affect the outcome. - - 'tests/performance/**' - # Confirm any changes to relevant workflow files. - '.github/workflows/performance.yml' - '.github/workflows/reusable-performance-*.yml' workflow_dispatch: diff --git a/.github/workflows/php-compatibility.yml b/.github/workflows/php-compatibility.yml index 4bae7e0a381b0..7bb6869fd5a79 100644 --- a/.github/workflows/php-compatibility.yml +++ b/.github/workflows/php-compatibility.yml @@ -13,13 +13,51 @@ on: - '5.[5-9]' - '[6-9].[0-9]' paths: - # This workflow only scans PHP files. - - '**.php' - # These files configure Composer. Changes could affect the outcome. + - '**' + # Documentation, repository metadata, and local environment configuration. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.env.example' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.jshintrc' + - '!.mailmap' + - '!docker-compose.yml' + - '!jsdoc.conf.json' + - '!typings/**' + - '!wp-cli.yml' + # File types that the PHP compatibility scan does not inspect. + - '!**.crt' + - '!**.css' + - '!**.dat' + - '!**.dist' + - '!**.html' + - '!**.jpg' + - '!**.js' + - '!**.json' + - '!**.map' + - '!**.mo' + - '!**.neon' + - '!**.pem' + - '!**.png' + - '!**.po' + - '!**.scss' + - '!**.svg' + - '!**.txt' + - '!**.webp' + - '!**.woff2' + - '!**.xml' + - '!**.yaml' + - '!**.yml' + # Only source PHP files are scanned. + - '!*.php' + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include configuration and workflow files that affect the scan. - 'composer.*' - # This file configures PHP compatibility scanning. Changes could affect the outcome. - 'phpcompat.xml.dist' - # Confirm any changes to relevant workflow files. - '.github/workflows/php-compatibility.yml' - '.github/workflows/reusable-php-compatibility.yml' workflow_dispatch: diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index 45e1439c9b604..aea51a37d3cdb 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -12,26 +12,39 @@ on: - '3.[7-9]' - '[4-9].[0-9]' paths: - # Any change to a PHP, CSS, JavaScript, JSON, HTML, or otherwise tested file should run checks. - - '**.css' - - '**.html' - - '**.js' - - '**.json' - - '**.php' + - '**' + # Documentation and repository metadata. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!typings/**' + # Configuration for unrelated checks. + - '!.eslintrc-jsdoc.js' + - '!.jshintrc' + - '!.prettierrc.js' + - '!.version-support-*.json' + - '!eslint.config.js' + - '!jsdoc.conf.json' + - '!phpcompat.xml.dist' + - '!phpcs.xml.dist' + - '!phpstan.neon.dist' + - '!phpunit.xml.dist' + - '!tsconfig.json' + - '!webpack.config.js' + # Other test suites, tools, and workflows do not affect these tests. + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include documentation, tests, tools, and workflows used here. + - 'SECURITY.md' - 'src/license.txt' - - 'src/SECURITY.md' - # These files configure npm and the task runner. Changes could affect the outcome. - - 'package*.json' - - '.npmrc' - - '.nvmrc' - - 'Gruntfile.js' - # These files configure Composer. Changes could affect the outcome. - - 'composer.*' - # These files affect the phpunit tests. Changes could affect the outcome. - 'tests/phpunit/**' - - 'tests/phpunit/multisite.xml' + - 'tools/gutenberg/**' + - 'tools/local-env/**' - 'phpunit.xml.dist' - # Confirm any changes to relevant workflow files. - '.github/workflows/phpunit-tests.yml' - '.github/workflows/reusable-phpunit-tests-*.yml' - '.github/workflows/reusable-prepare-gutenberg.yml' diff --git a/.github/workflows/test-build-processes.yml b/.github/workflows/test-build-processes.yml index cd32d99cacb1f..bfabbb855ef18 100644 --- a/.github/workflows/test-build-processes.yml +++ b/.github/workflows/test-build-processes.yml @@ -12,23 +12,38 @@ on: - '3.[7-9]' - '[4-9].[0-9]' paths: - # Any change to a PHP, CSS, JavaScript, or JSON file should run checks. - - '**.css' - - '**.js' - - '**.json' - - '**.php' - # These files configure npm and the task runner. Changes could affect the outcome. - - 'package*.json' - - '.npmrc' - - '.nvmrc' - - 'Gruntfile.js' - - 'webpack.config.js' + - '**' + # Documentation, repository metadata, and local environment configuration. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.env.example' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!docker-compose.yml' + - '!typings/**' + - '!wp-cli.yml' + # Configuration for unrelated checks. + - '!.eslintrc-jsdoc.js' + - '!.jshintrc' + - '!.prettierrc.js' + - '!.version-support-*.json' + - '!eslint.config.js' + - '!jsdoc.conf.json' + - '!phpcompat.xml.dist' + - '!phpcs.xml.dist' + - '!phpstan.neon.dist' + - '!phpunit.xml.dist' + - '!tsconfig.json' + # Tests, unrelated tools, and other workflows do not affect the build. + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include the tools and workflows used by the build. - 'tools/gutenberg/**' - 'tools/vendors/**' - 'tools/webpack/**' - # These files configure Composer. Changes could affect the outcome. - - 'composer.*' - # Confirm any changes to relevant workflow files. - '.github/workflows/test-build-processes.yml' - '.github/workflows/reusable-test-core-build-process.yml' workflow_dispatch: diff --git a/.github/workflows/upgrade-develop-testing.yml b/.github/workflows/upgrade-develop-testing.yml index eb0c4ac3fdedc..5911999c7cb54 100644 --- a/.github/workflows/upgrade-develop-testing.yml +++ b/.github/workflows/upgrade-develop-testing.yml @@ -12,6 +12,7 @@ on: paths: # Any change to a source PHP file should run checks. - 'src/**.php' + - '*.php' # PHP files in the root, like wp-config-sample.php. # Confirm any changes to relevant workflow files. - '.github/workflows/upgrade-develop-testing.yml' - '.github/workflows/reusable-upgrade-testing.yml' @@ -23,6 +24,7 @@ on: paths: # Any change to a source PHP file should run checks. - 'src/**.php' + - '*.php' # PHP files in the root, like wp-config-sample.php. # Confirm any changes to relevant workflow files. - '.github/workflows/upgrade-develop-testing.yml' - '.github/workflows/reusable-upgrade-testing.yml'