Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 06113cf

Browse files
authored
Merge pull request #1260 from PHPCSStandards/feature/changelog-4.0.0
Changelog for the 4.0.0 release
2 parents 7bb1928 + 68e414d commit 06113cf

File tree

3 files changed

+48
-3
lines changed

3 files changed

+48
-3
lines changed

‎CHANGELOG-4.x.md‎

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,47 @@
22

33
The file documents changes to the PHP_CodeSniffer project for the 4.x series of releases.
44

5+
## [4.0.0] - 2025年09月16日
6+
7+
This release contains breaking changes.
8+
9+
Upgrade guides for both [ruleset maintainers/end-users][wiki-upgrade-4.0-end-users], as well as for [sniff developers and integrators][wiki-upgrade-4.0-extenders], have been published to the Wiki.
10+
11+
You are strongly encouraged to read the upgrade guide applicable to your situation before upgrading.
12+
13+
This release includes all improvements and bugfixes from PHP_CodeSniffer [3.13.3] and [3.13.4].
14+
15+
### Changed
16+
- Tokenizer/PHP: fully qualified `exit`/`die`/`true`/`false`/`null` will be tokenized as the keyword token and the token `'content'` will include the leading backslash. [#1201]
17+
- Wherever possible based on the PHP 7.2 minimum version, parameter types have been added to all methods. [#1237]
18+
- The supported PHPUnit version constraints have been updated to `^8.4.0 || ^9.3.4 || ^10.5.32 || 11.3.3 - 11.5.28 || ^11.5.31`. [#1247]
19+
- External standards using the PHP_CodeSniffer native framework may need to update their own PHPUnit version constraints.
20+
- Various housekeeping, including improvements to the tests and documentation.
21+
22+
### Fixed
23+
- Fixed bug [#1082]: new exit codes weren't applied when running `phpcbf` on code provided via STDIN.
24+
- Thanks to [Dan Wallis][@fredden] for the patch.
25+
- Fixed bug [#1172]: `// phpcs:set` for inline array properties did not handle a single item array with the value `true`, `false` or `null` correctly.
26+
- Fixed bug [#1174]: progress bar wasn't showing files as fixed when running `phpcbf` in parallel mode.
27+
- Fixed bug [#1226]: PHP 8.5 "Using null as an array offset" deprecation notice.
28+
29+
### Other
30+
- Please be aware that the `master` branch has been renamed to `3.x` and the default branch has changed to the `4.x` branch.
31+
- If you contribute to PHP_CodeSniffer, you will need to update your local git clone.
32+
- If you develop against PHP_CodeSniffer and run your tests against dev branches of PHPCS, you will need to update your workflows.
33+
34+
[3.13.3]: https://github.com/PHPCSStandards/PHP_CodeSniffer/blob/4.x/CHANGELOG-3.x.md#3133---2025年09月04日
35+
[3.13.4]: https://github.com/PHPCSStandards/PHP_CodeSniffer/blob/4.x/CHANGELOG-3.x.md#3134---2025年09月05日
36+
37+
[#1082]: https://github.com/PHPCSStandards/PHP_CodeSniffer/issues/1082
38+
[#1172]: https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/1172
39+
[#1174]: https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/1174
40+
[#1201]: https://github.com/PHPCSStandards/PHP_CodeSniffer/issues/1201
41+
[#1226]: https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/1226
42+
[#1237]: https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/1237
43+
[#1247]: https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/1247
44+
45+
546
## [4.0.0RC1] - 2025年06月18日
647

748
This release includes all improvements and bugfixes from PHP_CodeSniffer [3.13.1] and [3.13.2].
@@ -268,12 +309,15 @@ This release includes all improvements and bugfixes from PHP_CodeSniffer [3.13.1
268309
**Calling all testers!**
269310

270311
Please help by testing the beta release and reporting any issues you run into.
271-
Upgrade guides for both [ruleset maintainers/end-users](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Version-4.0-User-Upgrade-Guide), as well as for [sniff developers and integrators](https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Version-4.0-Developer-Upgrade-Guide), have been published to the Wiki to help smooth the transition.
312+
Upgrade guides for both [ruleset maintainers/end-users][wiki-upgrade-4.0-end-users], as well as for [sniff developers and integrators][wiki-upgrade-4.0-extenders], have been published to the Wiki to help smooth the transition.
272313

273314
All patches courtesy of [Greg Sherwood][@gsherwood] and [Juliette Reinders Folmer][@jrfnl].
274315

275316
Special thanks go out to [Dan Wallis][@fredden] and [Rodrigo Primo][@rodrigoprimo] for their reviews and feedback.
276317

318+
[wiki-upgrade-4.0-end-users]: https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Version-4.0-User-Upgrade-Guide
319+
[wiki-upgrade-4.0-extenders]: https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki/Version-4.0-Developer-Upgrade-Guide
320+
277321
[sq-1595]: https://github.com/squizlabs/PHP_CodeSniffer/issues/1595
278322
[sq-1612]: https://github.com/squizlabs/PHP_CodeSniffer/issues/1612
279323
[sq-1908]: https://github.com/squizlabs/PHP_CodeSniffer/issues/1908
@@ -348,6 +392,7 @@ Special thanks go out to [Dan Wallis][@fredden] and [Rodrigo Primo][@rodrigoprim
348392
=== Link list for release links ====
349393
-->
350394

395+
[4.0.0]: https://github.com/PHPCSStandards/PHP_CodeSniffer/compare/4.0.0RC1...4.0.0
351396
[4.0.0RC1]: https://github.com/PHPCSStandards/PHP_CodeSniffer/compare/4.0.0beta1...4.0.0RC1
352397
[4.0.0beta1]: https://github.com/PHPCSStandards/PHP_CodeSniffer/compare/3.13.0...4.0.0beta1
353398

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ Or alternatively, include a dependency for `squizlabs/php_codesniffer` in your `
6464
```json
6565
{
6666
"require-dev": {
67-
"squizlabs/php_codesniffer": "^3.0"
67+
"squizlabs/php_codesniffer": "^4.0"
6868
}
6969
}
7070
```

‎src/Config.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ class Config
9797
*
9898
* @var string
9999
*/
100-
public const STABILITY = 'RC';
100+
public const STABILITY = 'stable';
101101

102102
/**
103103
* Default report width when no report width is provided and 'auto' does not yield a valid width.

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /