Problem/Motivation
FILE: C:\xampp\htdocs\abc\drupal\modules\fieldory\fieldory.module
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...upal\modules\fieldory\fieldory_examples\fieldory_examples.module
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...dory\fieldory_examples\src\Commands\FieldoryExamplesCommands.php
----------------------------------------------------------------------
FOUND 6 ERRORS AND 1 WARNING AFFECTING 7 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
23 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
85 | ERROR | [ ] The array declaration extends to column 88 (the
| | limit is 80). The array content should be split
| | up over multiple lines
90 | ERROR | [ ] The array declaration extends to column 95 (the
| | limit is 80). The array content should be split
| | up over multiple lines
95 | ERROR | [ ] The array declaration extends to column 95 (the
| | limit is 80). The array content should be split
| | up over multiple lines
124 | ERROR | [x] Inline comments must start with a capital letter
126 | ERROR | [x] Inline comments must end in full-stops,
| | exclamation marks, question marks, colons, or
| | closing parentheses
----------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: C:\xampp\htdocs\abc\drupal\modules\fieldory\README.md
----------------------------------------------------------------------
FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
----------------------------------------------------------------------
8 | WARNING | Line exceeds 80 characters; contains 117 characters
24 | WARNING | Line exceeds 80 characters; contains 147 characters
----------------------------------------------------------------------
FILE: ...p\htdocs\abc\drupal\modules\fieldory\src\Annotation\Fieldory.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
11 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...\htdocs\abc\drupal\modules\fieldory\src\Constants\FieldoryId.php
----------------------------------------------------------------------
FOUND 3 ERRORS AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
5 | ERROR | [x] Missing class doc comment
16 | ERROR | [x] The closing brace for the class must have an empty
| | line before it
----------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...upal\modules\fieldory\src\Exception\InvalidFieldoryException.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
5 | ERROR | [x] Non-namespaced classes/interfaces/traits should
| | not be referenced with use statements
11 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...fieldory\src\Exception\InvalidFrequentlyUsedOptionsException.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
5 | ERROR | [x] Non-namespaced classes/interfaces/traits should
| | not be referenced with use statements
11 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...upal\modules\fieldory\src\Exception\InvalidPropertyException.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
5 | ERROR | [x] Non-namespaced classes/interfaces/traits should
| | not be referenced with use statements
11 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...l\modules\fieldory\src\Exception\ModuleNotInstalledException.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
5 | ERROR | [x] Non-namespaced classes/interfaces/traits should
| | not be referenced with use statements
11 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: C:\xampp\htdocs\abc\drupal\modules\fieldory\src\FieldoryBase.php
----------------------------------------------------------------------
FOUND 6 ERRORS AND 2 WARNINGS AFFECTING 7 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
479 | WARNING | [x] Inline @var declarations should use the /** */
| | delimiters
520 | WARNING | [x] Inline @var declarations should use the /** */
| | delimiters
581 | ERROR | [x] Missing function doc comment
607 | ERROR | [ ] Description for the @return value is missing
619 | ERROR | [ ] Missing parameter comment
631 | ERROR | [ ] Missing parameter comment
631 | ERROR | [ ] Missing parameter type
----------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...\xampp\htdocs\abc\drupal\modules\fieldory\src\FieldoryBundle.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
13 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...mpp\htdocs\abc\drupal\modules\fieldory\src\FieldoryInterface.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
9 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...xampp\htdocs\abc\drupal\modules\fieldory\src\FieldoryManager.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...fieldory\src\FrequentlyUsedOptions\BoolFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...ieldory\src\FrequentlyUsedOptions\FloatFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 6 ERRORS AND 1 WARNING AFFECTING 7 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
15 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
19 | ERROR | [x] Doc comment short description must end with a
| | full stop
49 | ERROR | [ ] Missing parameter comment
50 | ERROR | [ ] Missing parameter comment
51 | ERROR | [ ] Missing parameter comment
52 | ERROR | [ ] Missing parameter comment
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...ldory\src\FrequentlyUsedOptions\IntegerFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 6 ERRORS AND 1 WARNING AFFECTING 7 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
15 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
19 | ERROR | [x] Doc comment short description must end with a
| | full stop
49 | ERROR | [ ] Missing parameter comment
50 | ERROR | [ ] Missing parameter comment
51 | ERROR | [ ] Missing parameter comment
52 | ERROR | [ ] Missing parameter comment
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...y\src\FrequentlyUsedOptions\ListIntegerFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
14 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
39 | ERROR | [ ] Type hint "array" missing for $options
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...ory\src\FrequentlyUsedOptions\ParagraphFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 3 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
13 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
26 | ERROR | [ ] Missing parameter comment
26 | ERROR | [x] Data types in @param tags need to be fully
| | namespaced
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...fieldory\src\FrequentlyUsedOptions\TermFrequentlyUsedOptions.php
----------------------------------------------------------------------
FOUND 3 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
9 | ERROR | [x] There must be one blank line after the last USE
| | statement; 2 found;
9 | ERROR | [x] When importing a class with "use", do not include
| | a leading \
16 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...cs\abc\drupal\modules\fieldory\src\FrequentlyUsedOptionsBase.php
----------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n" but
| | found "\r\n"
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...cs\abc\drupal\modules\fieldory\src\Plugin\Fieldory\BoolField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
16 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...s\abc\drupal\modules\fieldory\src\Plugin\Fieldory\FloatField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
16 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...abc\drupal\modules\fieldory\src\Plugin\Fieldory\IntegerField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
16 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...drupal\modules\fieldory\src\Plugin\Fieldory\ListIntegerField.php
----------------------------------------------------------------------
FOUND 2 ERRORS AND 1 WARNING AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
16 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
32 | ERROR | [x] Expected 1 blank line after function; 2 found
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...c\drupal\modules\fieldory\src\Plugin\Fieldory\MonthYearField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
14 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...c\drupal\modules\fieldory\src\Plugin\Fieldory\ParagraphField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 2 WARNINGS AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
7 | WARNING | [x] Unused use statement
17 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...\abc\drupal\modules\fieldory\src\Plugin\Fieldory\StringField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
14 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...c\drupal\modules\fieldory\src\Plugin\Fieldory\TelephoneField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
14 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...cs\abc\drupal\modules\fieldory\src\Plugin\Fieldory\TermField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 2 WARNINGS AFFECTING 3 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
6 | WARNING | [x] Unused use statement
17 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
FILE: ...bc\drupal\modules\fieldory\src\Plugin\Fieldory\TextLongField.php
----------------------------------------------------------------------
FOUND 1 ERROR AND 1 WARNING AFFECTING 2 LINES
----------------------------------------------------------------------
1 | ERROR | [x] End of line character is invalid; expected "\n"
| | but found "\r\n"
14 | WARNING | [ ] The class short comment should describe what the
| | class does and not simply repeat the class name
----------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
----------------------------------------------------------------------
Steps to reproduce
Run the following command :
phpcs --standard="Drupal,DrupalPractice" --extensions=php,module,inc,install,test,profile,theme,info,txt,md,yml /10.1.x/drupal/modules/contrib/fieldory
Proposed resolution
Fix all the PHP coding standard issues.