Problem/Motivation
FILE: block_component_library\block_component_library.info.yml
-------------------------------------------------------------------------------------------------------------
FOUND 0 ERRORS AND 3 WARNINGS AFFECTING 1 LINE
-------------------------------------------------------------------------------------------------------------
1 | WARNING | Remove "project" from the info file, it will be added by drupal.org packaging automatically
1 | WARNING | Remove "datestamp" from the info file, it will be added by drupal.org packaging automatically
1 | WARNING | Remove "version" from the info file, it will be added by drupal.org packaging automatically
-------------------------------------------------------------------------------------------------------------
FILE: block_component_library\block_component_library.install
-----------------------------------------------------------------------------------------------------------------------------
FOUND 42 ERRORS AND 4 WARNINGS AFFECTING 30 LINES
-----------------------------------------------------------------------------------------------------------------------------
1 | ERROR | [x] Missing file doc comment
1 | ERROR | [x] End of line character is invalid; expected "\n" but found "\r\n"
4 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is Drupal\field\Entity\FieldConfig.
16 | ERROR | [x] Expected 1 space after IF keyword; 0 found
16 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
21 | ERROR | [x] Line indented incorrectly; expected 6 spaces, found 4
21 | ERROR | [x] Object operator not indented correctly; expected 6 spaces but found 4
25 | WARNING | [x] A comma should follow the last multiline array item. Found: ]
29 | ERROR | [x] Expected 1 space after FOREACH keyword; 0 found
29 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
30 | ERROR | [x] Expected 1 space after IF keyword; 0 found
30 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
36 | ERROR | [x] Expected 1 space after IF keyword; 0 found
36 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
39 | ERROR | [x] Expected 1 space after IF keyword; 0 found
39 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
48 | ERROR | [x] Expected 1 space before opening brace; found 0
50 | ERROR | [x] Expected 1 space after IF keyword; 0 found
50 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
54 | ERROR | [x] Expected 1 space after IF keyword; 0 found
54 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
62 | ERROR | [x] Parameter comment must be on the next line
62 | ERROR | [x] Parameter comment must end with a full stop
63 | ERROR | [x] Parameter comment must be on the next line
64 | ERROR | [x] Parameter comment must be on the next line
65 | ERROR | [x] Separate the @param and @return sections by a blank line.
65 | ERROR | [x] Expected "bool" but found "boolean" for function return type
65 | ERROR | [ ] Description for the @return value is missing
67 | ERROR | [x] Expected 1 space before opening brace; found 0
69 | WARNING | [ ] Line exceeds 80 characters; contains 82 characters
92 | ERROR | [x] Line indented incorrectly; expected 8 spaces, found 6
92 | ERROR | [x] Object operator not indented correctly; expected 8 spaces but found 6
96 | WARNING | [x] A comma should follow the last multiline array item. Found: ]
102 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE" but found "false"
106 | WARNING | [ ] Line exceeds 80 characters; contains 88 characters
107 | ERROR | [ ] Doc comment short description must be on a single line, further text should be a separate paragraph
109 | ERROR | [x] Expected "bool" but found "boolean" for function return type
109 | ERROR | [ ] Description for the @return value is missing
111 | ERROR | [x] Expected 1 space before opening brace; found 0
118 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE" but found "false"
124 | ERROR | [ ] Function return type is void, but function contains return statement
124 | ERROR | [ ] Description for the @return value is missing
126 | ERROR | [x] Expected 1 space before opening brace; found 0
129 | ERROR | [x] Expected 1 space after IF keyword; 0 found
129 | ERROR | [x] Expected 1 space after closing parenthesis; found 0
132 | ERROR | [x] TRUE, FALSE and NULL must be uppercase; expected "FALSE" but found "false"
-----------------------------------------------------------------------------------------------------------------------------
PHPCBF CAN FIX THE 39 MARKED SNIFF VIOLATIONS AUTOMATICALLY
-----------------------------------------------------------------------------------------------------------------------------
Steps to reproduce
Run phpcs command to get the drupal coding standard issues.
Proposed resolution
Many of the issues can be fixed by running the phpcbf command. For the remaining ones, we will need to manually address and then commit these changes before pushing them.
Issue fork block_component_library-3475744
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
sunil jolapara commentedComment #5
anybodyThanks @sunil jolapara could you also fix phpcs and cspell here?
Comment #6
anybodyComment #7
cleavinjosh commentedComment #8
cleavinjosh commentedNo more phpcs issues found.
Comment #9
cleavinjosh commentedNo more cspell issues found.
Comment #10
cleavinjosh commentedHi,
I am not sure if it is safe to change the "Aktion" and the "preconfiguration" being flagged so I just added them to a dictionary.
Please review, check, and advise on MR!4. Thank you.
Comment #11
anybodyblock_component_library.install is unacceptable this way, please look yourself.
Comment #12
cleavinjosh commentedComment #13
cleavinjosh commentedHi @anybody,
Thank you for your feedback, especially on the cspell issue. It is greatly appreciated!
Please review, check, and advise. Thank you.
Comment #14
anybodyThe display of the changes in the .install file is a bit weird but seems all fine. Thanks!
Comment #16
anybody