phpcs coding standard

Created on 6 February 2023, almost 2 years ago
Updated 20 February 2023, over 1 year ago

ILE: ...rupal_cms/drupal9/web/themes/contrib/portfollio_theme/Resume.libraries.yml
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
8 | ERROR | [x] Expected 1 newline at end of file; 2 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...tml/drupal_cms/drupal9/web/themes/contrib/portfollio_theme/Resume.info.yml
--------------------------------------------------------------------------------
FOUND 1 ERROR AFFECTING 1 LINE
--------------------------------------------------------------------------------
20 | ERROR | [x] Expected 1 newline at end of file; 2 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: .../html/drupal_cms/drupal9/web/themes/contrib/portfollio_theme/css/style.css
--------------------------------------------------------------------------------
FOUND 115 ERRORS AFFECTING 115 LINES
--------------------------------------------------------------------------------
1 | ERROR | [x] Selectors must be on a single line
2 | ERROR | [x] Selectors must be on a single line
3 | ERROR | [x] Selectors must be on a single line
200 | ERROR | [x] Blank lines are not allowed in class definitions
233 | ERROR | [x] Blank lines are not allowed in class definitions
241 | ERROR | [x] Blank lines are not allowed in class definitions
242 | ERROR | [x] Blank lines are not allowed in class definitions
406 | ERROR | [x] Blank lines are not allowed in class definitions
438 | ERROR | [x] Blank lines are not allowed in class definitions
464 | ERROR | [x] Blank lines are not allowed in class definitions
561 | ERROR | [x] Whitespace found at end of line
574 | ERROR | [x] Whitespace found at end of line
578 | ERROR | [x] Whitespace found at end of line
586 | ERROR | [x] Whitespace found at end of line
593 | ERROR | [x] Whitespace found at end of line
603 | ERROR | [x] Whitespace found at end of line
609 | ERROR | [x] Whitespace found at end of line
613 | ERROR | [x] Whitespace found at end of line
624 | ERROR | [x] Whitespace found at end of line
642 | ERROR | [x] Blank lines are not allowed in class definitions
683 | ERROR | [x] Blank lines are not allowed in class definitions
717 | ERROR | [x] Blank lines are not allowed in class definitions
741 | ERROR | [x] Blank lines are not allowed in class definitions
745 | ERROR | [x] Blank lines are not allowed in class definitions
751 | ERROR | [x] Blank lines are not allowed in class definitions
755 | ERROR | [x] Blank lines are not allowed in class definitions
761 | ERROR | [x] Blank lines are not allowed in class definitions
765 | ERROR | [x] Blank lines are not allowed in class definitions
771 | ERROR | [x] Blank lines are not allowed in class definitions
775 | ERROR | [x] Blank lines are not allowed in class definitions
781 | ERROR | [x] Blank lines are not allowed in class definitions
785 | ERROR | [x] Blank lines are not allowed in class definitions
791 | ERROR | [x] Blank lines are not allowed in class definitions
793 | ERROR | [x] Blank lines are not allowed in class definitions
798 | ERROR | [x] Blank lines are not allowed in class definitions
804 | ERROR | [x] Blank lines are not allowed in class definitions
811 | ERROR | [x] Blank lines are not allowed in class definitions
817 | ERROR | [x] Blank lines are not allowed in class definitions
823 | ERROR | [x] Blank lines are not allowed in class definitions
829 | ERROR | [x] Blank lines are not allowed in class definitions
833 | ERROR | [x] Blank lines are not allowed in class definitions
837 | ERROR | [x] Blank lines are not allowed in class definitions
844 | ERROR | [x] Blank lines are not allowed in class definitions
851 | ERROR | [x] Blank lines are not allowed in class definitions
852 | ERROR | [x] Blank lines are not allowed in class definitions
854 | ERROR | [x] Blank lines are not allowed in class definitions
855 | ERROR | [x] Blank lines are not allowed in class definitions
863 | ERROR | [x] Blank lines are not allowed in class definitions
868 | ERROR | [x] Blank lines are not allowed in class definitions
878 | ERROR | [x] Blank lines are not allowed in class definitions
886 | ERROR | [x] Blank lines are not allowed in class definitions
890 | ERROR | [x] Blank lines are not allowed in class definitions
891 | ERROR | [x] Blank lines are not allowed in class definitions
901 | ERROR | [x] Blank lines are not allowed in class definitions
905 | ERROR | [x] Blank lines are not allowed in class definitions
913 | ERROR | [x] Blank lines are not allowed in class definitions
918 | ERROR | [x] Blank lines are not allowed in class definitions
925 | ERROR | [x] Blank lines are not allowed in class definitions
931 | ERROR | [x] Blank lines are not allowed in class definitions
935 | ERROR | [ ] More than 2 empty lines are not allowed
939 | ERROR | [ ] More than 2 empty lines are not allowed
1032 | ERROR | [x] Whitespace found at end of line
1045 | ERROR | [x] Whitespace found at end of line
1049 | ERROR | [x] Whitespace found at end of line
1057 | ERROR | [x] Whitespace found at end of line
1064 | ERROR | [x] Whitespace found at end of line
1074 | ERROR | [x] Whitespace found at end of line
1080 | ERROR | [x] Whitespace found at end of line
1084 | ERROR | [x] Whitespace found at end of line
1095 | ERROR | [x] Whitespace found at end of line
1112 | ERROR | [x] Blank lines are not allowed in class definitions
1152 | ERROR | [x] Blank lines are not allowed in class definitions
1185 | ERROR | [x] Blank lines are not allowed in class definitions
1187 | ERROR | [x] Blank lines are not allowed in class definitions
1189 | ERROR | [x] Blank lines are not allowed in class definitions
1198 | ERROR | [x] Blank lines are not allowed in class definitions
1199 | ERROR | [x] Blank lines are not allowed in class definitions
1215 | ERROR | [x] Blank lines are not allowed in class definitions
1219 | ERROR | [x] Blank lines are not allowed in class definitions
1225 | ERROR | [x] Blank lines are not allowed in class definitions
1229 | ERROR | [x] Blank lines are not allowed in class definitions
1235 | ERROR | [x] Blank lines are not allowed in class definitions
1239 | ERROR | [x] Blank lines are not allowed in class definitions
1245 | ERROR | [x] Blank lines are not allowed in class definitions
1249 | ERROR | [x] Blank lines are not allowed in class definitions
1255 | ERROR | [x] Blank lines are not allowed in class definitions
1259 | ERROR | [x] Blank lines are not allowed in class definitions
1265 | ERROR | [x] Blank lines are not allowed in class definitions
1267 | ERROR | [x] Blank lines are not allowed in class definitions
1272 | ERROR | [x] Blank lines are not allowed in class definitions
1278 | ERROR | [x] Blank lines are not allowed in class definitions
1285 | ERROR | [x] Blank lines are not allowed in class definitions
1291 | ERROR | [x] Blank lines are not allowed in class definitions
1297 | ERROR | [x] Blank lines are not allowed in class definitions
1303 | ERROR | [x] Blank lines are not allowed in class definitions
1307 | ERROR | [x] Blank lines are not allowed in class definitions
1311 | ERROR | [x] Blank lines are not allowed in class definitions
1318 | ERROR | [x] Blank lines are not allowed in class definitions
1325 | ERROR | [x] Blank lines are not allowed in class definitions
1329 | ERROR | [x] Blank lines are not allowed in class definitions
1331 | ERROR | [x] Blank lines are not allowed in class definitions
1332 | ERROR | [x] Blank lines are not allowed in class definitions
1340 | ERROR | [x] Blank lines are not allowed in class definitions
1345 | ERROR | [x] Blank lines are not allowed in class definitions
1354 | ERROR | [x] Blank lines are not allowed in class definitions
1361 | ERROR | [x] Blank lines are not allowed in class definitions
1365 | ERROR | [x] Blank lines are not allowed in class definitions
1366 | ERROR | [x] Blank lines are not allowed in class definitions
1376 | ERROR | [x] Blank lines are not allowed in class definitions
1377 | ERROR | [x] Blank lines are not allowed in class definitions
1385 | ERROR | [x] Blank lines are not allowed in class definitions
1390 | ERROR | [x] Blank lines are not allowed in class definitions
1397 | ERROR | [x] Blank lines are not allowed in class definitions
1403 | ERROR | [x] Blank lines are not allowed in class definitions
1404 | ERROR | [x] Expected 1 newline at end of file; 0 found
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 113 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: ...w/html/drupal_cms/drupal9/web/themes/contrib/portfollio_theme/Resume.theme
--------------------------------------------------------------------------------
FOUND 46 ERRORS AND 1 WARNING AFFECTING 24 LINES
--------------------------------------------------------------------------------
1 | ERROR | [x] The PHP open tag must be followed by exactly one blank line
1 | ERROR | [x] Missing file doc comment
2 | WARNING | [x] Unused use statement
2 | ERROR | [x] There must be one blank line after the last USE statement;
| | 0 found;
7 | ERROR | [x] You must use "/**" style comments for a function comment
8 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
8 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
9 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
9 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
10 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
10 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
12 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
12 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
13 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
13 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
14 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
14 | ERROR | [x] Line indented incorrectly; expected 6 spaces, found 3
15 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
15 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
15 | ERROR | [x] Expected newline after closing brace
16 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
16 | ERROR | [x] Line indented incorrectly; expected 6 spaces, found 3
17 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
17 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
18 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
18 | ERROR | [x] Line indented incorrectly; expected 4 spaces, found 2
19 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
19 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
20 | ERROR | [x] Expected 1 blank line after function; 0 found
21 | ERROR | [x] Missing function doc comment
21 | ERROR | [ ] Invalid function name, expected resume_preprocess_page but
| | found Resume_preprocess_page
22 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
22 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
23 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
23 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
24 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
24 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
25 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
25 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
26 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
26 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
27 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
27 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
28 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
28 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
29 | ERROR | [x] Spaces must be used to indent lines; tabs are not allowed
29 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 1
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 46 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

FILE: .../drupal_cms/drupal9/web/themes/contrib/portfollio_theme/theme-settings.php
--------------------------------------------------------------------------------
FOUND 21 ERRORS AFFECTING 20 LINES
--------------------------------------------------------------------------------
8 | ERROR | [x] Missing function doc comment
8 | ERROR | [ ] Invalid function name, expected
| | resume_form_system_theme_settings_alter but found
| | Resume_form_system_theme_settings_alter
15 | ERROR | [ ] Inline doc block comments are not allowed; use "/* Comment
| | */" or "// Comment" instead
37 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 4
38 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
39 | ERROR | [x] Array indentation error, expected 6 spaces but found 4
40 | ERROR | [x] Array closing indentation error, expected 4 spaces but found
| | 2
47 | ERROR | [x] Whitespace found at end of line
48 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
49 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
54 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
61 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
62 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
67 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
74 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
75 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
80 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
87 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
88 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
93 | ERROR | [x] Line indented incorrectly; expected 2 spaces, found 0
99 | ERROR | [x] Functions must not contain multiple empty lines in a row;
| | found 2 empty lines
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 19 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------

Time: 1.04 secs; Memory: 18MB

🐛 Bug report
Status

RTBC

Version

1.0

Component

Code

Created by

🇮🇳India vishal365365

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @vishal365365
  • Issue was unassigned.
  • Status changed to Needs review almost 2 years ago
  • 🇮🇳India vishal365365

    i have fixed this issue. Please review it

  • 🇮🇳India nayana_mvr

    Verified the patch #2 and tested it on Drupal version 10.1.x and Portfollio Theme 1.0.x. Patch applied cleanly but there are few more coding standard issues

    FILE: ../portfollio_theme/Resume.theme
    --------------------------------------------------------------------------------------------------------------------
    FOUND 4 ERRORS AND 1 WARNING AFFECTING 5 LINES
    --------------------------------------------------------------------------------------------------------------------
      6 | ERROR   | Doc comment short description must be on a single line, further text should be a separate paragraph
      9 | ERROR   | Doc comment is empty
     28 | ERROR   | Doc comment is empty
     31 | ERROR   | Invalid function name, expected resume_preprocess_page but found Resume_preprocess_page
     32 | WARNING | Unused variable $config.
    --------------------------------------------------------------------------------------------------------------------
    
    
    FILE: ../portfollio_theme/css/style.css
    -------------------------------------------------------------------------------------------------
    FOUND 2 ERRORS AFFECTING 2 LINES
    -------------------------------------------------------------------------------------------------
     885 | ERROR | More than 2 empty lines are not allowed
     889 | ERROR | More than 2 empty lines are not allowed
    -------------------------------------------------------------------------------------------------
    
    
    FILE: ../portfollio_theme/theme-settings.php
    ----------------------------------------------------------------------------------------------------------------------------------------
    FOUND 3 ERRORS AFFECTING 3 LINES
    ----------------------------------------------------------------------------------------------------------------------------------------
      8 | ERROR | Doc comment is empty
     11 | ERROR | Invalid function name, expected resume_form_system_theme_settings_alter but found Resume_form_system_theme_settings_alter
     18 | ERROR | Inline doc block comments are not allowed; use "/* Comment */" or "// Comment" instead
    ----------------------------------------------------------------------------------------------------------------------------------------
    
    Time: 187ms; Memory: 16MB
    
  • 🇮🇳India rassoni Bangalore

    Fixed above mention PHP Standards.

  • @rashmisoni opened merge request.
  • 🇮🇳India nayana_mvr

    Reviewed patch #4. Except the following warning, all other coding standard issues are fixed.

    FILE: .../portfollio_theme/Resume.theme
    ------------------------------------------------------------------------------------------------
    FOUND 0 ERRORS AND 1 WARNING AFFECTING 1 LINE
    ------------------------------------------------------------------------------------------------
     31 | WARNING | Unused variable $config.
    ------------------------------------------------------------------------------------------------
    
    Time: 131ms; Memory: 10MB
  • 🇮🇳India Adil_Siddiqui

    Patch created with above and all issue fixes

  • Status changed to RTBC over 1 year ago
  • 🇮🇳India nayana_mvr

    Reviewed the patch #7 in Drupal version 10.1.x and Portfollio Theme version 1.0.x. All the coding standard issues are fixed now.

Production build 0.71.5 2024