Skip to content

PHPCS workflow adjustments - #3356

Open
lukasdchang wants to merge 4 commits into
aws:masterfrom
lukasdchang:formatter-adjustments
Open

lukasdchang wants to merge 4 commits into
aws:masterfrom
lukasdchang:formatter-adjustments

Conversation

@lukasdchang

@lukasdchang lukasdchang commented Sep 16, 2026

Copy link
Copy Markdown
Contributor

Description

PHPCBF printed long fixed-code excerpts in GitHub Actions. Release PRs also failed PHPCS on generated service clients and exceptions that use the SDK's compact class format.

This change updates the coding standards workflow to keep log output short and scope PHPCS exceptions to generated service stubs.

Changes:

  • Move changed PHP file detection into .github/scripts/find-changed-source-files.sh.
  • Check changed PHP files under src/, excluding src/data/.
  • Replace PHPCBF fixed-code excerpts with Git diffs.
  • Exclude generated service clients and service exceptions from three formatting rules:
    • PSR12.Files.FileHeader.SpacingAfterBlock
    • PSR2.Classes.ClassDeclaration.OpenBraceNewLine
    • Squiz.WhiteSpace.ScopeClosingBrace.ContentBefore

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@lukasdchang
lukasdchang marked this pull request as ready for review September 18, 2026 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants