From aead5ef7dfa642ebb107e7b599a8200970c8854e Mon Sep 17 00:00:00 2001 From: WorkOfStan Date: Sun, 20 Sep 2026 15:29:49 +0200 Subject: [PATCH 1/3] chore(deps): bump actions/cache from 5 to 6 --- CHANGELOG.md | 2 +- action.yml | 14 +++++++++----- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d5c4368..e83750d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,7 +30,7 @@ fix(action): wire composite action outputs ### Changed -- ci(GitHub): bump actions/checkout to v7 and actions/cache to v5 +- ci(GitHub): bump actions/checkout to v7 and actions/cache to v6 - docs(README): add PHPCS customization examples, common standards guidance, and troubleshooting notes - shorten subject to fit most 80 characters - Clarify the maintained PHPCS Composer package and cache reuse behavior, and rename the installation step to reflect cache misses. diff --git a/action.yml b/action.yml index ed7b9a3..ac04235 100644 --- a/action.yml +++ b/action.yml @@ -33,7 +33,8 @@ inputs: description: "Comma delimited list of extensions to be sniffed" required: false type: string - default: "php" # "php,inc,lib" + # "php,inc,lib" + default: "php" ignore: description: "Ignore files based on a comma-separated list of patterns matching files and/or directories." required: false @@ -48,7 +49,8 @@ inputs: description: "The name of, or the path to, the coding standard to use. Can be a comma-separated list specifying multiple standards." required: false type: string - default: "" # if left empty, .github/linters/phpcs.xml or https://github.com/super-linter/super-linter/blob/main/TEMPLATES/phpcs.xml will be used + # if left empty, .github/linters/phpcs.xml or https://github.com/super-linter/super-linter/blob/main/TEMPLATES/phpcs.xml will be used + default: "" stop-on-manual-fix: description: "If true, the execution will stop when manual fixes are necessary." type: boolean @@ -72,8 +74,10 @@ runs: - name: Checkout code uses: actions/checkout@v7 with: - ref: ${{ github.ref }} # Fetch latest changes (even by previous job) - fetch-depth: 0 # Fetch all history for all branches and tags. Otherwise github.event.pull_request.base.ref SHA isn't found. + # Fetch latest changes (even by previous job) + ref: ${{ github.ref }} + # Fetch all history for all branches and tags. Otherwise github.event.pull_request.base.ref SHA isn't found. + fetch-depth: 0 # Fetch latest changes (even by previous job) - name: Fetch latest changes @@ -90,7 +94,7 @@ runs: # A repository can have up to 10 GB of caches. Once the 10 GB limit is reached, older caches will be evicted based on when the cache was last accessed. # Caches that are not accessed within the last week will also be evicted. - name: Cache composer dependencies - uses: actions/cache@v5 + uses: actions/cache@v6 id: vendor-cache with: # path to Checkout working directory is /home/runner/work/repo-name/repo-name , so just add /vendor/ From 7f700cb6ddfbbc1ce3336d0429b4a6849ac265ef Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 20 Sep 2026 13:30:09 +0000 Subject: [PATCH 2/3] chore(prettier): apply Prettier fixes automatically on 2026-09-20 13:30:09 UTC --- README.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 7dcd407..d861a0e 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ permissions: | Input | Description | Type | Default | | -------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `commit-changes` | If set to `true`, the action will commit changes to the current branch; otherwise a new branch is created for manual review. | Boolean | `false` | -| `commit-message` | Commit message prefix; the action appends a UTC timestamp (`on YYYY-MM-DD HH:MM:SS UTC`). | String | `"chore(phpcf): apply PHP Code Beautifier fixes"` | +| `commit-message` | Commit message prefix; the action appends a UTC timestamp (`on YYYY-MM-DD HH:MM:SS UTC`). | String | `"chore(phpcf): apply PHP Code Beautifier fixes"` | | `debug` | Enable extra debug output (list of branches). | Boolean | `false` | | `extensions` | Comma-delimited list of file extensions to be sniffed. Note: an empty value will disable checking. | String | `"php"` (defaults to PHP only; other file types must be specified) | | `ignore` | Ignore files based on a comma-separated list of patterns matching files and/or directories. | String | `vendor/` | @@ -69,9 +69,9 @@ jobs: uses: WorkOfStan/phpcs-fix@v1 with: commit-changes: true - extensions: 'php,phtml,inc' - ignore: 'vendor/*,storage/*,bootstrap/cache/*' - standard: 'PSR12' + extensions: "php,phtml,inc" + ignore: "vendor/*,storage/*,bootstrap/cache/*" + standard: "PSR12" ``` Examples by input: @@ -101,20 +101,20 @@ Select it explicitly in the workflow step: - name: Run PHPCS fix with a custom ruleset uses: WorkOfStan/phpcs-fix@v1 with: - standard: '.phpcs.xml' + standard: ".phpcs.xml" ``` This example keeps PSR12 checks except the line-length sniff. Use `vendor/bin/phpcs -s` locally with your ruleset to see sniff codes in reports. See the [annotated ruleset reference](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Annotated-Ruleset) for more exclusion options. ### Common Standards -| Standard | When to use it | Documentation | -| -------- | -------------- | ------------- | -| `PSR12` | A good default for modern PHP applications and libraries. | [PSR-12 specification](https://www.php-fig.org/psr/psr-12/) | -| `PEAR` | Useful for projects that already follow PEAR-style conventions or need compatibility with older codebases. | [PEAR Coding Standards](https://pear.php.net/manual/en/standards.php) | -| `Squiz` | Stricter built-in PHPCS standard with broader formatting and consistency checks than PSR-12. | [PHPCS usage and installed standards](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Usage#printing-a-list-of-installed-coding-standards) | -| `Zend` | Helpful for legacy Zend Framework style codebases that already align with that convention. | [PHPCS usage and installed standards](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Usage#printing-a-list-of-installed-coding-standards) | -| Custom ruleset | Best when your team needs project-specific sniffs, exclusions, or severity overrides. | [Annotated ruleset reference](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Annotated-Ruleset) | +| Standard | When to use it | Documentation | +| -------------- | ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | +| `PSR12` | A good default for modern PHP applications and libraries. | [PSR-12 specification](https://www.php-fig.org/psr/psr-12/) | +| `PEAR` | Useful for projects that already follow PEAR-style conventions or need compatibility with older codebases. | [PEAR Coding Standards](https://pear.php.net/manual/en/standards.php) | +| `Squiz` | Stricter built-in PHPCS standard with broader formatting and consistency checks than PSR-12. | [PHPCS usage and installed standards](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Usage#printing-a-list-of-installed-coding-standards) | +| `Zend` | Helpful for legacy Zend Framework style codebases that already align with that convention. | [PHPCS usage and installed standards](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Usage#printing-a-list-of-installed-coding-standards) | +| Custom ruleset | Best when your team needs project-specific sniffs, exclusions, or severity overrides. | [Annotated ruleset reference](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Annotated-Ruleset) | If you are not sure where to start, try `standard: 'PSR12'` first and move to a project-local ruleset when you need exceptions or additional sniffs. From f503f5804ab44b5367b8c35a725f2f16da5cf160 Mon Sep 17 00:00:00 2001 From: WorkOfStan Date: Sun, 20 Sep 2026 15:39:06 +0200 Subject: [PATCH 3/3] docs: fix natural language --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e83750d..ff21ee6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -31,14 +31,14 @@ fix(action): wire composite action outputs ### Changed - ci(GitHub): bump actions/checkout to v7 and actions/cache to v6 -- docs(README): add PHPCS customization examples, common standards guidance, and troubleshooting notes +- docs(readme): add PHPCS customization examples, common standards guidance, and troubleshooting notes - shorten subject to fit most 80 characters - Clarify the maintained PHPCS Composer package and cache reuse behavior, and rename the installation step to reflect cache misses. ### Fixed - fix(action): wire composite action outputs `branch-name` and `changed-files` to step outputs -- Correct README action terminology, commit-message defaults, fallback ruleset and failure descriptions, and maintained documentation links. +- Correct readme action terminology, commit-message defaults, fallback ruleset and failure descriptions, and maintained documentation links. ## [1.0.4] - 2025-10-23