squizlabs / PHP_CodeSniffer

PHP_CodeSniffer tokenizes PHP files and detects violations of a defined set of coding standards.
BSD 3-Clause "New" or "Revised" License
10.66k stars 1.48k forks source link

Ruleset::explain(): use natural sorting #3868

Closed jrfnl closed 9 months ago

jrfnl commented 1 year ago

Description

Use natural sorting for the list of included sniffs.

The SORT_NATURAL and the SORT_FLAG_CASE flag are available since PHP 5.4, so can be used without issue.

Suggested changelog entry

The -e (explain) command will now list sniffs in natural order.

Types of changes

jrfnl commented 9 months ago

Closing as replaced by https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/79