Skip to content

Releases: inpsyde/php-coding-standards

v0.8.0

13 Feb 19:18
Compare
Choose a tag to compare
  • Fix bug in NoAccessorsSniff and allow for a few method names related to PHP core interfaces.
  • Exclude ArrayAccess methods from ReturnTypeDeclarationSniff and ArgumentTypeDeclarationSniff.
  • Fix bug in LineLengthSniff which affected edge cases.
  • Changed default LineLengthSniff max length to 100, excluding leading indent.
  • Remove Variable Analysis, too much false positives

v0.7.2

13 Feb 08:46
Compare
Choose a tag to compare
  • Fixed bug in ReturnTypeDeclarationSniff which caused wrong return type detection.

v0.7.1

12 Feb 19:47
Compare
Choose a tag to compare
  • Exclude NeutronStandard.MagicMethods.RiskyMagicMethod
  • Add .gitattributes
  • Update own styles in phpcs

v0.7.0

12 Feb 19:33
Compare
Choose a tag to compare
  • Removed NeutronStandard.Conditions.DisallowConditionAssignWithoutConditional.
  • Removed NeutronStandard.MagicMethods.DisallowMagicGet.
  • Removed NeutronStandard.MagicMethods.DisallowMagicSet.
  • Made NeutronStandard.Whitespace.DisallowMultipleNewlines.MultipleNewlines a warning not error.
  • Added custom AssignmentInsideConditionSniff sniff.
  • Added custom NoTopLevelDefineSniff sniff.

v0.6.0

12 Feb 16:24
Compare
Choose a tag to compare
  • Missing return type waring from ReturnTypeDeclarationSniff skipped for hook callbacks.
  • Fixed a bug in return counting in helper class that affected few sniffs.
  • Add several "Generic" and "Squiz" rules.
  • Add DisallowShortOpenTagSniff that extends the generic sniff allowing short echo.
  • Remove NeutronStandard.Constants.DisallowDefine because of github.com/Automattic/phpcs-neutron-standard/issues/44
  • Renamed configuration properties for FunctionLengthSniff.
  • Add integration tests for custom sniffs.
  • Rename NoASetterSniff to NoAccessorsSniff and also warn for getters.

v0.5.1

05 Feb 14:03
Compare
Choose a tag to compare
  • ArgumentTypeDeclarationSniff also skip function and methods that declare @wp-hook doc param.

v0.5.0

05 Feb 13:45
Compare
Choose a tag to compare
  • Disabled NeutronStandard.Functions.TypeHint and replaced with custom sniffs
  • Added ArgumentTypeDeclarationSniff to replace NeutronStandard.Functions.TypeHint sniff for
    missing argument types.
    It does not check closures used as hook callbacks (because WP cannot be trusted on types).
  • Added ReturnTypeDeclarationSniff to replace NeutronStandard.Functions.TypeHint sniff for
    missing or wrong return type.
  • Added HookClosureReturnSniff to sniff closures added to filters and missing return values and
    closures added to action and having return values.

v0.4.2

05 Feb 07:45
Compare
Choose a tag to compare
  • Fix a bug in FunctionLengthSniff which only excludes first doc block
  • FunctionLengthSniff also excludes (by default) blank lines and single line comments
  • Introduce phpcs.xml
  • Small improvements to ruleset
  • Use own styles

v0.4.1

01 Feb 14:35
Compare
Choose a tag to compare
  • FunctionLengthSniff now excludes doc blocks lines from counting
  • New LineLengthSniff (that replaces "Generic" sniff included by "PSR2") and ignores long lines coming from translation functions first argument

v0.4.0

01 Feb 14:34
Compare
Choose a tag to compare
  • Rename custom rules namespace from CodingStandard to InpsydeCodingStandard