@@ -3153,36 +3153,55 @@ Additionally, thanks to [Alexander Turek][@derrabus] for consulting on the repo
3153
3153
3154
3154
## [ 2.6.2] - 2016-07-14
3155
3155
### Changed
3156
- - Added a new --exclude CLI argument to exclude a list of sniffs from checking and fixing (request #904 )
3156
+ - Added a new --exclude CLI argument to exclude a list of sniffs from checking and fixing (request [ #904 ] )
3157
3157
- Accepts the same sniff codes as the --sniffs command line argument, but provides the opposite functionality
3158
- - Added a new -q command line argument to disable progress and verbose information from being printed (request #969 )
3158
+ - Added a new -q command line argument to disable progress and verbose information from being printed (request [ #969 ] )
3159
3159
- Useful if a coding standard hard-codes progress or verbose output but you want PHPCS to be quiet
3160
3160
- Use the command "phpcs --config-set quiet true" to turn quiet mode on by default
3161
- - Generic LineLength sniff no longer errors for comments that cannot be broken out onto a new line (request #766 )
3161
+ - Generic LineLength sniff no longer errors for comments that cannot be broken out onto a new line (request [ #766 ] )
3162
3162
- A typical case is a comment that contains a very long URL
3163
- - The comment is ignored if putting the URL on a indented new comment line would be longer than the allowed length
3163
+ - The comment is ignored if putting the URL on an indented new comment line would be longer than the allowed length
3164
3164
- Settings extensions in a ruleset no longer causes PHP notices during unit testing
3165
3165
- Thanks to [ Klaus Purer] [ @klausi ] for the patch
3166
3166
- Version control reports now show which errors are fixable if you are showing sources
3167
- - Added a new sniff to enforce a single space after a NOT operator (request #1051 )
3167
+ - Added a new sniff to enforce a single space after a NOT operator (request [ #1051 ] )
3168
3168
- Include in a ruleset using the code Generic.Formatting.SpaceAfterNot
3169
- - The Squiz.Commenting.BlockComment sniff now supports tabs for indenting comment lines (request #1056 )
3169
+ - The Squiz.Commenting.BlockComment sniff now supports tabs for indenting comment lines (request [ #1056 ] )
3170
3170
3171
3171
### Fixed
3172
- - Fixed bug #790 : Incorrect missing @throws error in methods that use closures
3173
- - Fixed bug #908 : PSR2 standard is not checking that closing brace is on line following the body
3174
- - Fixed bug #945 : Incorrect indent behavior using deep-nested function and arrays
3175
- - Fixed bug #961 : Two anonymous functions passed as function/method arguments cause indentation false positive
3176
- - Fixed bug #1005 : Using global composer vendor autoload breaks PHP lowercase built-in function sniff
3172
+ - Fixed bug [ #790 ] : Incorrect missing @throws error in methods that use closures
3173
+ - Fixed bug [ #908 ] : PSR2 standard is not checking that closing brace is on line following the body
3174
+ - Fixed bug [ #945 ] : Incorrect indent behavior using deep-nested function and arrays
3175
+ - Fixed bug [ #961 ] : Two anonymous functions passed as function/method arguments cause indentation false positive
3176
+ - Fixed bug [ #1005 ] : Using global composer vendor autoload breaks PHP lowercase built-in function sniff
3177
3177
- Thanks to [ Michael Butler] [ @michaelbutler ] for the patch
3178
- - Fixed bug #1007 : Squiz Unreachable code detection is not working properly with a closure inside a case
3179
- - Fixed bug #1023 : PSR2.Classes.ClassDeclaration fails if class extends base class and "implements" is on trailing line
3180
- - Fixed bug #1026 : Arrays in comma delimited class properties cause ScopeIndent to increase indent
3181
- - Fixed bug #1028 : Squiz ArrayDeclaration incorrectly fixes multi-line array where end bracket is not on a new line
3182
- - Fixed bug #1034 : Squiz FunctionDeclarationArgumentSpacing gives incorrect error when first arg is a variadic
3183
- - Fixed bug #1036 : Adjacent assignments aligned analysis statement wrong
3184
- - Fixed bug #1049 : Version control reports can show notices when the report width is very small
3185
- - Fixed bug #21050 : PEAR MultiLineCondition sniff suppresses errors on last condition line
3178
+ - Fixed bug [ #1007 ] : Squiz Unreachable code detection is not working properly with a closure inside a case
3179
+ - Fixed bug [ #1023 ] : PSR2.Classes.ClassDeclaration fails if class extends base class and "implements" is on trailing line
3180
+ - Fixed bug [ #1026 ] : Arrays in comma delimited class properties cause ScopeIndent to increase indent
3181
+ - Fixed bug [ #1028 ] : Squiz ArrayDeclaration incorrectly fixes multi-line array where end bracket is not on a new line
3182
+ - Fixed bug [ #1034 ] : Squiz FunctionDeclarationArgumentSpacing gives incorrect error when first arg is a variadic
3183
+ - Fixed bug [ #1036 ] : Adjacent assignments aligned analysis statement wrong
3184
+ - Fixed bug [ #1049 ] : Version control reports can show notices when the report width is very small
3185
+ - Fixed bug [ #21050 ] : PEAR MultiLineCondition sniff suppresses errors on last condition line
3186
+
3187
+ [ #766 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/766
3188
+ [ #790 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/790
3189
+ [ #904 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/904
3190
+ [ #908 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/908
3191
+ [ #945 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/945
3192
+ [ #961 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/961
3193
+ [ #969 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/969
3194
+ [ #1005 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1005
3195
+ [ #1007 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1007
3196
+ [ #1023 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1023
3197
+ [ #1026 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1026
3198
+ [ #1028 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1028
3199
+ [ #1034 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1034
3200
+ [ #1036 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1036
3201
+ [ #1049 ] : https://github.com/squizlabs/PHP_CodeSniffer/pull/1049
3202
+ [ #1051 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1051
3203
+ [ #1056 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1056
3204
+ [ #21050 ] : https://pear.php.net/bugs/bug.php?id=21050
3186
3205
3187
3206
## [ 2.6.1] - 2016-05-31
3188
3207
### Changed
@@ -3191,43 +3210,60 @@ Additionally, thanks to [Alexander Turek][@derrabus] for consulting on the repo
3191
3210
- Thanks to [ Jaroslav Hanslík] [ @kukulich ] for the patch
3192
3211
- The default_standard config setting now allows multiple standards to be listed, like on the command line
3193
3212
- Thanks to [ Michael Mayer] [ @schnittstabil ] for the patch
3194
- - Installations done via composer now only include the composer autoloader for PHP 5.3.2+ (request #942 )
3213
+ - Installations done via composer now only include the composer autoloader for PHP 5.3.2+ (request [ #942 ] )
3195
3214
- Added a rollbackChangeset() method to the Fixer class to purposely rollback the active changeset
3196
3215
3197
3216
### Fixed
3198
- - Fixed bug #940 : Auto-fixing issue encountered with inconsistent use of braces
3199
- - Fixed bug #943 : Squiz.PHP.InnerFunctions.NotAllowed reported in anonymous classes
3200
- - Fixed bug #944 : PHP warning when running the latest phar
3201
- - Fixed bug #951 : InlineIfDeclaration: invalid error produced with UTF-8 string
3202
- - Fixed bug #957 : Operator spacing sniff errors when plus is used as part of a number
3217
+ - Fixed bug [ #940 ] : Auto-fixing issue encountered with inconsistent use of braces
3218
+ - Fixed bug [ #943 ] : Squiz.PHP.InnerFunctions.NotAllowed reported in anonymous classes
3219
+ - Fixed bug [ #944 ] : PHP warning when running the latest phar
3220
+ - Fixed bug [ #951 ] : InlineIfDeclaration: invalid error produced with UTF-8 string
3221
+ - Fixed bug [ #957 ] : Operator spacing sniff errors when plus is used as part of a number
3203
3222
- Thanks to [ Klaus Purer] [ @klausi ] for the patch
3204
- - Fixed bug #959 : Call-time pass-by-reference false positive if there is a square bracket before the ampersand
3223
+ - Fixed bug [ #959 ] : Call-time pass-by-reference false positive if there is a square bracket before the ampersand
3205
3224
- Thanks to [ Konstantin Leboev] [ @realmfoo ] for the patch
3206
- - Fixed bug #962 : Null coalescing operator (??) not detected as a token
3225
+ - Fixed bug [ #962 ] : Null coalescing operator (??) not detected as a token
3207
3226
- Thanks to [ Joel Posti] [ @joelposti ] for the patch
3208
- - Fixed bug #973 : Anonymous class declaration and PSR1.Files.SideEffects.FoundWithSymbols
3209
- - Fixed bug #974 : Error when file ends with "function"
3210
- - Fixed bug #979 : Anonymous function with return type hint is not refactored as expected
3211
- - Fixed bug #983 : Squiz.WhiteSpace.MemberVarSpacing.AfterComment fails to fix error when comment is not a docblock
3212
- - Fixed bug #1010 : Squiz NonExecutableCode sniff does not detect boolean OR
3227
+ - Fixed bug [ #973 ] : Anonymous class declaration and PSR1.Files.SideEffects.FoundWithSymbols
3228
+ - Fixed bug [ #974 ] : Error when file ends with "function"
3229
+ - Fixed bug [ #979 ] : Anonymous function with return type hint is not refactored as expected
3230
+ - Fixed bug [ #983 ] : Squiz.WhiteSpace.MemberVarSpacing.AfterComment fails to fix error when comment is not a docblock
3231
+ - Fixed bug [ #1010 ] : Squiz NonExecutableCode sniff does not detect boolean OR
3213
3232
- Thanks to [ Derek Henderson] [ @2shediac ] for the patch
3214
- - Fixed bug #1015 : The Squiz.Commenting.FunctionComment sniff doesn't allow description in @return tag
3233
+ - Fixed bug [ #1015 ] : The Squiz.Commenting.FunctionComment sniff doesn't allow description in @return tag
3215
3234
- Thanks to [ Alexander Obuhovich] [ @aik099 ] for the patch
3216
- - Fixed bug #1022 : Duplicate spaces after opening bracket error with PSR2 standard
3217
- - Fixed bug #1025 : Syntax error in JS file can cause undefined index for parenthesis_closer
3235
+ - Fixed bug [ #1022 ] : Duplicate spaces after opening bracket error with PSR2 standard
3236
+ - Fixed bug [ #1025 ] : Syntax error in JS file can cause undefined index for parenthesis_closer
3237
+
3238
+ [ #940 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/940
3239
+ [ #942 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/942
3240
+ [ #943 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/943
3241
+ [ #944 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/944
3242
+ [ #951 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/951
3243
+ [ #957 ] : https://github.com/squizlabs/PHP_CodeSniffer/pull/957
3244
+ [ #959 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/959
3245
+ [ #962 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/962
3246
+ [ #973 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/973
3247
+ [ #974 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/974
3248
+ [ #979 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/979
3249
+ [ #983 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/983
3250
+ [ #1010 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1010
3251
+ [ #1015 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1015
3252
+ [ #1022 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1022
3253
+ [ #1025 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/1025
3218
3254
3219
3255
## [ 2.6.0] - 2016-04-04
3220
3256
### Changed
3221
- - Paths used when setting CLI arguments inside ruleset.xml files are now relative to the ruleset location (request #847 )
3257
+ - Paths used when setting CLI arguments inside ruleset.xml files are now relative to the ruleset location (request [ #847 ] )
3222
3258
- This change only applies to paths within ARG tags, used to set CLI arguments
3223
3259
- Previously, the paths were relative to the directory PHPCS was being run from
3224
3260
- Absolute paths are still allowed and work the same way they always have
3225
3261
- This change allows ruleset.xml files to be more portable
3226
3262
- Content passed via STDIN will now be processed even if files are specified on the command line or in a ruleset
3227
- - When passing content via STDIN, you can now specify the file path to use on the command line (request #934 )
3263
+ - When passing content via STDIN, you can now specify the file path to use on the command line (request [ #934 ] )
3228
3264
- This allows sniffs that check file paths to work correctly
3229
3265
- This is the same functionality provided by the phpcs_input_file line, except it is available on the command line
3230
- - Files processed with custom tokenizers will no longer be skipped if they appear minified (request #877 )
3266
+ - Files processed with custom tokenizers will no longer be skipped if they appear minified (request [ #877 ] )
3231
3267
- If the custom tokenizer wants minified files skipped, it can set a $skipMinified member var to TRUE
3232
3268
- See the included JS and CSS tokenizers for an example
3233
3269
- Config vars set in ruleset.xml files are now processed earlier, allowing them to be used during sniff registration
@@ -3238,12 +3274,12 @@ Additionally, thanks to [Alexander Turek][@derrabus] for consulting on the repo
3238
3274
- You can still manually set php_path to use a specific binary for testing
3239
3275
- Thanks to [ Andrew Berry] [ @deviantintegral ] for the patch
3240
3276
- The PHP-supplied T_POW_EQUAL token has been replicated for PHP versions before 5.6
3241
- - Added support for PHP7 use group declarations (request #878 )
3277
+ - Added support for PHP7 use group declarations (request [ #878 ] )
3242
3278
- New tokens T_OPEN_USE_GROUP and T_CLOSE_USE_GROUP are assigned to the open and close curly braces
3243
- - Generic ScopeIndent sniff now reports errors for every line that needs the indent changed (request #903 )
3279
+ - Generic ScopeIndent sniff now reports errors for every line that needs the indent changed (request [ #903 ] )
3244
3280
- Previously, it ignored lines that were indented correctly in the context of their block
3245
3281
- This change produces more technically accurate error messages, but is much more verbose
3246
- - The PSR2 and Squiz standards now allow multi-line default values in function declarations (request #542 )
3282
+ - The PSR2 and Squiz standards now allow multi-line default values in function declarations (request [ #542 ] )
3247
3283
- Previously, these would automatically make the function a multi-line declaration
3248
3284
- Squiz InlineCommentSniff now allows docblocks on require(_ once) and include(_ once) statements
3249
3285
- Thanks to [ Gary Jones] [ @GaryJones ] for the patch
@@ -3255,31 +3291,56 @@ Additionally, thanks to [Alexander Turek][@derrabus] for consulting on the repo
3255
3291
- Renamed Squiz.CSS.Opacity.SpacingAfterPoint to Squiz.CSS.Opacity.DecimalPrecision
3256
3292
- Please update your ruleset if you are referencing this error code directly
3257
3293
- Fixed PHP tokenizer problem that caused an infinite loop when checking a comment with specific content
3258
- - Generic Disallow Space and Tab indent sniffs now detect and fix indents inside embedded HTML chunks (request #882 )
3294
+ - Generic Disallow Space and Tab indent sniffs now detect and fix indents inside embedded HTML chunks (request [ #882 ] )
3259
3295
- Squiz CSS IndentationSniff no longer assumes the class opening brace is at the end of a line
3260
3296
- Squiz FunctionCommentThrowTagSniff now ignores non-docblock comments
3261
3297
- Squiz ComparisonOperatorUsageSniff now allows conditions like while(true)
3262
3298
- PEAR FunctionCallSignatureSniff (and the Squiz and PSR2 sniffs that use it) now correctly check the first argument
3263
- - Further fix for bug #698
3299
+ - Further fix for bug [ #698 ]
3264
3300
3265
3301
### Fixed
3266
- - Fixed bug #791 : codingStandardsChangeSetting settings not working with namespaces
3267
- - Fixed bug #872 : Incorrect detection of blank lines between CSS class names
3268
- - Fixed bug #879 : Generic InlineControlStructureSniff can create parse error when case/if/elseif/else have mixed brace and braceless definitions
3269
- - Fixed bug #883 : PSR2 is not checking for blank lines at the start and end of control structures
3270
- - Fixed bug #884 : Incorrect indentation notice for anonymous classes
3271
- - Fixed bug #887 : Using curly braces for a shared CASE/DEFAULT statement can generate an error in PSR2 SwitchDeclaration
3272
- - Fixed bug #889 : Closure inside catch/else/elseif causes indentation error
3273
- - Fixed bug #890 : Function call inside returned short array value can cause indentation error inside CASE statements
3274
- - Fixed bug #897 : Generic.Functions.CallTimePassByReference.NotAllowed false positive when short array syntax
3275
- - Fixed bug #900 : Squiz.Functions.FunctionDeclarationArgumentSpacing bug when no space between type hint and argument
3276
- - Fixed bug #902 : T_OR_EQUAL and T_POW_EQUAL are not seen as assignment tokens
3277
- - Fixed bug #910 : Unrecognized "extends" and indentation on anonymous classes
3278
- - Fixed bug #915 : JS Tokenizer generates errors when processing some decimals
3279
- - Fixed bug #928 : Endless loop when sniffing a PHP file with a git merge conflict inside a function
3280
- - Fixed bug #937 : Shebang can cause PSR1 SideEffects warning
3302
+ - Fixed bug [ #791 ] : codingStandardsChangeSetting settings not working with namespaces
3303
+ - Fixed bug [ #872 ] : Incorrect detection of blank lines between CSS class names
3304
+ - Fixed bug [ #879 ] : Generic InlineControlStructureSniff can create parse error when case/if/elseif/else have mixed brace and braceless definitions
3305
+ - Fixed bug [ #883 ] : PSR2 is not checking for blank lines at the start and end of control structures
3306
+ - Fixed bug [ #884 ] : Incorrect indentation notice for anonymous classes
3307
+ - Fixed bug [ #887 ] : Using curly braces for a shared CASE/DEFAULT statement can generate an error in PSR2 SwitchDeclaration
3308
+ - Fixed bug [ #889 ] : Closure inside catch/else/elseif causes indentation error
3309
+ - Fixed bug [ #890 ] : Function call inside returned short array value can cause indentation error inside CASE statements
3310
+ - Fixed bug [ #897 ] : Generic.Functions.CallTimePassByReference.NotAllowed false positive when short array syntax
3311
+ - Fixed bug [ #900 ] : Squiz.Functions.FunctionDeclarationArgumentSpacing bug when no space between type hint and argument
3312
+ - Fixed bug [ #902 ] : T_OR_EQUAL and T_POW_EQUAL are not seen as assignment tokens
3313
+ - Fixed bug [ #910 ] : Unrecognized "extends" and indentation on anonymous classes
3314
+ - Fixed bug [ #915 ] : JS Tokenizer generates errors when processing some decimals
3315
+ - Fixed bug [ #928 ] : Endless loop when sniffing a PHP file with a git merge conflict inside a function
3316
+ - Fixed bug [ #937 ] : Shebang can cause PSR1 SideEffects warning
3281
3317
- Thanks to [ Clay Loveless] [ @claylo ] for the patch
3282
- - Fixed bug #938 : CallTimePassByReferenceSniff ignores functions with return value
3318
+ - Fixed bug [ #938 ] : CallTimePassByReferenceSniff ignores functions with return value
3319
+
3320
+ [ #542 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/542
3321
+ [ #698 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/698
3322
+ [ #791 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/791
3323
+ [ #847 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/847
3324
+ [ #872 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/872
3325
+ [ #877 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/877
3326
+ [ #878 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/878
3327
+ [ #879 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/879
3328
+ [ #882 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/882
3329
+ [ #883 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/883
3330
+ [ #884 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/884
3331
+ [ #887 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/887
3332
+ [ #889 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/889
3333
+ [ #890 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/890
3334
+ [ #897 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/897
3335
+ [ #900 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/900
3336
+ [ #902 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/902
3337
+ [ #903 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/903
3338
+ [ #910 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/910
3339
+ [ #915 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/915
3340
+ [ #928 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/928
3341
+ [ #934 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/934
3342
+ [ #937 ] : https://github.com/squizlabs/PHP_CodeSniffer/pull/937
3343
+ [ #938 ] : https://github.com/squizlabs/PHP_CodeSniffer/issues/938
3283
3344
3284
3345
## [ 2.5.1] - 2016-01-20
3285
3346
### Changed
0 commit comments