Ecosyste.ms: OpenCollective
An open API service for software projects hosted on Open Collective.
github.com/PHPCSStandards/PHPCSExtra
A collection of code standards for use with PHP_CodeSniffer
https://github.com/PHPCSStandards/PHPCSExtra
GH Actions: various tweaks / PHP 8.2 not allowed to fail
0b910d485c45f268df86d72d8a428fac8204f618 authored about 2 years ago by Juliette <[email protected]>PHP 8.2 has been released today :tada: and the `setup-php` action has announced support for PHP ...
5df2952c63e3847499ec80ceaac80094b1d4efc6 authored about 2 years ago by jrfnl <[email protected]>... of the bash `date` command in the earlier pulled cache busting.
bda1436a3e6cd033b72666a040edf13c1bbacf3e authored about 2 years ago by jrfnl <[email protected]>Modernize/Dirname: magic constants are case-insensitive
f0e76068fdd883c67467f005dda62b6630c0104c authored about 2 years ago by Juliette <[email protected]>Includes a few updated unit tests to safeguard the fix.
99e806c45ee2efe77e9d68db0973a096dd8bf63a authored about 2 years ago by jrfnl <[email protected]>GH Actions: add yaml linting and markdown QA
259ac2466cbd1ed204c076c646b303b4404ee05f authored about 2 years ago by Juliette <[email protected]>... to loosely safeguard valid and consistent yaml files.
Includes adding a configuration file ...
ed23b67ed07b7862d8b771fb1d60193baa4e1896 authored about 2 years ago by jrfnl <[email protected]>_Based on a similar workflow previously added to PHPCSUtils._
Remark offers a number of "rules"...
e2797fd6a41e808d0ee6b1acb4efedae4b95533c authored about 2 years ago by jrfnl <[email protected]>... to be before the adjustments made to the composer.json file.
ff912b107e34ac58abccfad1730c55b1a1116d1d authored about 2 years ago by jrfnl <[email protected]>Changelog: add missing link
23457671ce2e48f626cc0a3194cd83971cb2e834 authored about 2 years ago by Juliette <[email protected]>10d48af2eff24bc7cabc896e64ce33c67d2fd54b authored about 2 years ago by jrfnl <[email protected]>
Release version 1.0.-RC1
e0e58d3d807b08aaa26b3df1a4a04a01a1d4ffa0 authored about 2 years ago by Juliette <[email protected]>Documentation updates for the release of version 1.0.0-RC1
2dc1d34b9a79401d5a8045d42f95ad5490aad749 authored about 2 years ago by Juliette <[email protected]>67e0081f4e38a84979f0e7e67ef62e3e28bd87a2 authored about 2 years ago by jrfnl <[email protected]>
* Update links to workflows.
* Use re-usable links for links which are used repeatedly.
f480edc626ee77247689ba017c76daff5fff0a85 authored about 2 years ago by jrfnl <[email protected]>
20fb0ca34a636696478b7dba32fef21fe4529051 authored about 2 years ago by jrfnl <[email protected]>
GH Actions: various tweaks
30ae3f0954f233e8e3823c9b916b1ea8ce4d7672 authored about 2 years ago by Juliette <[email protected]>
* Update the PHP version on which the CS run for this package is run to PHP `latest`.
* Remove t...
These steps/directives all relate to testing against PHPCS 4.x, but this package is not being te...
d8b4f7d81d0154856542fc6a10cfa3c45711cc18 authored about 2 years ago by jrfnl <[email protected]>Ref: https://github.com/php-coveralls/php-coveralls/releases
6990e1c02d58544cd14b21eec5641844669f8c73 authored about 2 years ago by jrfnl <[email protected]>Composer: add PHPCSDevCS to the dependencies
ac62ed125488a67f74eebda2b1e5acd45f5331b7 authored about 2 years ago by Juliette <[email protected]>PHPCSDevCS was previously not added to the `require-dev` dependencies as the minimum supported P...
3626b56aaba40b8345e38e022772a0e18d746262 authored about 2 years ago by jrfnl <[email protected]>Universal/StaticInFinalClass: handle `static` when used in arrow function
5ee171e17eb7d6ef8eb0816c302bbcaed76e1e2d authored about 2 years ago by Juliette <[email protected]>... as long as the arrow function is within an OO construct which can be `final`.
Includes test...
fcaefe2030266b53eb41e6ec6afaa652871fd04a authored about 2 years ago by jrfnl <[email protected]>CS/QA: various minor fixes
d8e72f14e81f822af594a5bde11814072efc19d5 authored about 2 years ago by Juliette <[email protected]>b5113ceaafb4a0b57b33454f92b4822a1cf1a3e2 authored about 2 years ago by jrfnl <[email protected]>
... now upstream PR 3639 has been merged.
Ref:
* squizlabs/PHP_CodeSniffer 3639
cdf89be86ce98768c699509aeb47e15f7d08342c authored about 2 years ago by jrfnl <[email protected]>
f825da489f10fdc88f500c40db7a7b20fdb2cc72 authored about 2 years ago by jrfnl <[email protected]>
0a09645dc7b87c1354c7a85b3846d42839fd8b27 authored about 2 years ago by jrfnl <[email protected]>
Universal/DuplicateArrayKey: code simplification
0d4836bd45c32f9f930ac53c648ad5d0701de5eb authored about 2 years ago by Juliette <[email protected]>No functional changes.
7c4c3eae186f8f966d527d94c2dc1d3d39fbe9a8 authored about 2 years ago by jrfnl <[email protected]>Universal/DuplicateArrayKey: add support for detecting duplicate key PHP cross-version
91fb70189522c31692cb9ded229a24527bd1cca7 authored about 2 years ago by Juliette <[email protected]>How array keys for array items without keys are being determined, has changed in PHP 8.0.
Previ...
fe28363f9acb257b018195d555edc9a28b28c54e authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowStandalonePostIncrementDecrement: allow for statement ending with close tag
fa4fe20661dea6b15dcb075e70782d2c440cba07 authored about 2 years ago by Juliette <[email protected]>A stand-alone statement doesn't necessarily have to end with a semi-colon. It can also end on a ...
20a877e17cdc1397eff3d32e2fb564097b47db8a authored about 2 years ago by jrfnl <[email protected]>Universal/ForeachUniqueAssignment: improve analysis for foreach list assignments
e7a5b03e428caec4cbcbaec498779da2ea8663d7 authored about 2 years ago by Juliette <[email protected]>Universal/DisallowUse[Class|Const|Function]: minor code coverage tweak
440d8ea10860f60b32c6592d517fba9f2ba955c1 authored about 2 years ago by Juliette <[email protected]>Universal/NoReservedKeywordParameterNames: various improvements
becd4f02188d6df9ac2ee80f2e0a1e1786459b89 authored about 2 years ago by Juliette <[email protected]>
This commit:
* Prevents "accidentally correct" handling of code like `foreach ($data as [$id => ...
These tests weren't testing the sniff well enough.
514287786b99d3bc43d9f7594e2f5344bd93096f authored about 2 years ago by jrfnl <[email protected]>Ignore a statement which should never be reachable (defense in depth code).
b82be3e46879344342369cd2efa21c93c7f56564 authored about 2 years ago by jrfnl <[email protected]>... to confirm that properties set via the constructor are also checked.
Properties set via the...
35a2e51989bff4aebbffcd40b6afde71cc0ce735 authored about 2 years ago by jrfnl <[email protected]>While parameters (variables) are case-sensitive in PHP, keywords are not.
This commit improves ...
e78f25f429726ec82a484233f3eda7d6e6987e7d authored about 2 years ago by jrfnl <[email protected]>... to safeguard bowing out for function declarations without parameters and that the sniff stay...
b939740b8caf4f067c3439ab7fa0ea264855e001 authored about 2 years ago by jrfnl <[email protected]>b9dfb4dcfc71cccc083b461d8ec6fdb528324f14 authored about 2 years ago by jrfnl <[email protected]>
... which can be made now support for PHPCS < 3.7.1 has been dropped.
The sniff now only listen...
c7827ec582bcc98beb9a7c4321c698fb237bd3a3 authored about 2 years ago by jrfnl <[email protected]>✨ New Modernize.FunctionCalls.Dirname sniff
7cafca76bdbeeea9b3614ea1bb0fbb7428b4770e authored about 2 years ago by Juliette <[email protected]>This new sniff will detect and, when possible, auto-fix two typical code modernizations which ca...
1d3943dbee9a24ac1372978c056875a99ff86738 authored about 2 years ago by jrfnl <[email protected]>Includes updating CI and other dev related files to take the new standard into account.
5e0cdc6a22923586eae0d4fcdfa28c73f037fb28 authored about 2 years ago by jrfnl <[email protected]>Universal/SeparateFunctionsFromOO: update tests for arrow functions
7d9629e373b8c50fa93729d2b585dd457e85b61e authored about 2 years ago by Juliette <[email protected]>As the sniff uses predefined token collections from PHPCSUtils, it automatically takes PHP 7.4 a...
cc568b6b3d3d823f14da7d47aeed215caab3a3d2 authored about 2 years ago by jrfnl <[email protected]>Universal/SeparateFunctionsFromOO: update tests for enums
9e100d3bdad5fc8f967aa2d6420aa0d443b1f99b authored about 2 years ago by Juliette <[email protected]>Universal/DisallowLonelyIf: bow out early for a specific situation (PHP close tag)
3d4bb1922281e285bcca5c00b4eb93b4048797a2 authored about 2 years ago by Juliette <[email protected]>As the sniff uses predefined token collections from PHPCSUtils, it automatically takes PHP 8.1 `...
444fa6f6d15e050c979b7222497b25430b67f767 authored about 2 years ago by jrfnl <[email protected]>If an inner "if/else" chain using alternative syntax has a PHP close tag after the `endif` inste...
09df5315f707ce66d490318e6730da9d07566917 authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowLonelyIf: add extra test
e5fa39eb746373ee1d84c5e27a64f72239895cea authored about 2 years ago by Juliette <[email protected]>Universal/NoLeadingBackslash: examine imports within a group use statement
2827af24b92a1ec5f49629ea13f9a0cfc9194aae authored about 2 years ago by Juliette <[email protected]>.. to cover an edge case which is already handled correctly.
81b548b40a3fc2cbfb3398f859eeba741876f005 authored about 2 years ago by jrfnl <[email protected]>Previously the sniff would only examine the start of a complete import statement, now it will al...
588b7759575dce2e00e5fe6843f6a893b018d9a9 authored about 2 years ago by jrfnl <[email protected]>21ac4019189bb5c748f9514ae23de5bfcffedd71 authored about 2 years ago by jrfnl <[email protected]>
Universal/OneStatementInShortEchoTag: prevent false positive
45e3be33f278350feb57d4528d5d2198da3c5160 authored about 2 years ago by Juliette <[email protected]>Universal/RequireFinalClass: various tweaks
f1aa289bda537dd9db8af157e1baa5fb79c759a6 authored about 2 years ago by Juliette <[email protected]>Universal/DisallowFinalClass: various tweaks
9feee1f4f186ce03805d3728c8f4a3dae098b268 authored about 2 years ago by Juliette <[email protected]>Universal/RequireAnonClassParentheses: remove redundant condition
aee0f933acb718541294f826d816ac11d343f755 authored about 2 years ago by Juliette <[email protected]>Universal/DisallowAnonClassParentheses: remove redundant condition
65d41e186e131f7ca09a96b29d250cdbaa06a645 authored about 2 years ago by Juliette <[email protected]>... and annotate why the condition has been removed, as well as annotating a second likely redun...
1dc503bd829539e8732f70dcf6c1727914ac6d18 authored about 2 years ago by jrfnl <[email protected]>f5ebddb6afa788dac15f10415e214ad68e5977bf authored about 2 years ago by jrfnl <[email protected]>
As things were, the sniff would bow out if the opening brace for the class could not be found (y...
8bf00e38f2e3de0aaaeeabafc42299e38bbbc67c authored about 2 years ago by jrfnl <[email protected]>As things were, the sniff would bow out if the opening brace for the class could not be found (y...
59bb205548b07aa2be06d43e330bf6d8dd403c52 authored about 2 years ago by jrfnl <[email protected]>As things were, the sniff would bow out if the opening brace for the class could not be found (y...
324bc8f97f896857bab9c1ab59e768f80d6f0ea0 authored about 2 years ago by jrfnl <[email protected]>As things were, the sniff would bow out if the opening brace for the class could not be found (y...
9a1610c9d4c66ce16ac3f8f04b7af864c5f02f9d authored about 2 years ago by jrfnl <[email protected]>In convoluted code, which I hope to never encounter in real life, it _could_ be possible to enco...
579e7674d12187e5f46275a857162f8634eb5966 authored about 2 years ago by jrfnl <[email protected]>5d9f631fd9538e029a0269ade00da85e133cfc05 authored about 2 years ago by jrfnl <[email protected]>
e93bee2e2f9b865c5570bce9b911e4118d8df7cf authored about 2 years ago by jrfnl <[email protected]>
When a class is declared as `abstract`, it would attempt to record both for the `abstract`, as w...
4658e927229d05c49724a20bc2934f403e89840a authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowAlternativeSyntax: bug fix - handle if/elseif statements in one go
cecabbdb9aca2df19fdbe859b70e92d28f45988b authored about 2 years ago by Juliette <[email protected]>As things were, the sniff would examine - and potentially fix - each control structure keyword w...
df6ace718ca846b840931c7ce17ce84a07652ecc authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowAlternativeSyntax: bug fix - ignore inline HTML in nested closed scopes
6e4697f9f73042ff1be34ac1a9291021486ea8dc authored about 2 years ago by Juliette <[email protected]>... as the HTML in that case is not necessarily echo-ed out when the control structure is execut...
e4cfa4f86d857f502e4cb9d8a29b62a9a840366a authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowAlternativeSyntax: improve error message
538b90b6ef3d6ffa4048ecb90f7c7df7e81dd7ae authored about 2 years ago by Juliette <[email protected]>Group the setting of the `$code` and `$data` variables for the error message with the conditions...
dfc686e1a819378c8dfb254c3fa44306d974b9ec authored about 2 years ago by jrfnl <[email protected]>Improve the readability of the error message by moving the variable part to the end of the message.
18a26fd7f7214551ad35e0d79040ea9d5f731213 authored about 2 years ago by jrfnl <[email protected]>When the `$allowWithInlineHTML` property is set to `true`, the error message could be regarded a...
7d9dd20224181f432012eb72da1e2eeaa9647c6c authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowAlternativeSyntax: various tweaks
0448f4f03c58378e6d807e1f36abb3352333f44a authored about 2 years ago by Juliette <[email protected]>
* Minor tweak to the metric name.
* Also record metric for single line/no body control structures.
78ea24c41dd6e2e1407720f5d9b80fbdd6f08fff authored about 2 years ago by jrfnl <[email protected]>
When a control structure condition is directly followed by a PHP close tag, a semicolon is silen...
7e4732c037ac11f7cd71d2d384937ac2d45edf3b authored about 2 years ago by jrfnl <[email protected]>While empty "leafs" of control structures is allowed, it is less common, so make the code used f...
d7cb0568015af77613a8d165f65cc79efdffc043 authored about 2 years ago by jrfnl <[email protected]>GH Actions: bust the cache semi-regularly
376a1e31cee9cc7e98f29be73339fb237c947d43 authored about 2 years ago by Juliette <[email protected]>Caches used in GH Actions do not get updated, they can only be replaced by a different cache wit...
08dfa669cfa483241bc34c73aa50c6872443887a authored about 2 years ago by jrfnl <[email protected]>Universal/Disallow[Long|Short]ListSyntax: improve metrics
87406882e3a91ba59dc1cd3f3cf112c106dbff67 authored about 2 years ago by Juliette <[email protected]>Universal/DisallowShortArraySyntax: record metrics
d26dd5d6ed8cf0e12415d594f075e4191bb22f33 authored about 2 years ago by Juliette <[email protected]>Record both the `yes` as well as the `no`, which makes the metric feature complete.
51ffcd9467207cc39af5a9442a7f907269aed032 authored about 2 years ago by jrfnl <[email protected]>... as recording just and only the `no` is not a useful metric and adding the logic to also reco...
1b148e2a9ea62420afd1adaea852d65e136418b0 authored about 2 years ago by jrfnl <[email protected]>It's quite straight forward to record informative metrics for this sniff, so let's.
e0dc0d3f082b11d2e8c3dedaa29d15240ec2ebca authored about 2 years ago by jrfnl <[email protected]>Universal/DisallowShortArraySyntax: don't skip over short lists
d3e0f0b8141b5a206eeddd3f86f018674f879fda authored about 2 years ago by Juliette <[email protected]>Universal/DisallowShortListSyntax: bug fix - don't skip over nested brackets
e0c6bd0241ca3b2cae507d7bbeff22e49a9b789e authored about 2 years ago by Juliette <[email protected]>... as short arrays can contain short lists and those still need to be examined.
Includes test ...
39a1bc93c26827607731bc1e40a72b3bb45d7961 authored about 2 years ago by jrfnl <[email protected]>