- 🇮🇹Italy apaderno Brescia, 🇮🇹
The issue summary should always describe what the issue is trying to fix and, in the case, of coding standards issues, show which command has been used, which arguments have been used, and which report that command shown.
- Status changed to Needs review
over 1 year ago 7:19am 8 May 2023 - First commit to issue fork.
- 🇮🇳India rahulrasgon
rahulrasgon → changed the visibility of the branch 8.x-1.x to hidden.
- 🇮🇳India rahulrasgon
Patch provided in https://www.drupal.org/project/config_token/issues/3331946#comment-14858795 📌 Fix the issues reported by phpcs Needs review is relative to the project root directory not relative to the module directly.
Created the correct MR for easy merge https://git.drupalcode.org/project/config_token/-/merge_requests/3
Also verify by running the following command
phpcs --standard=“Drupal,DrupalPractice” --extensions=php,module,inc,install,test,profile,theme,info,txt,md,yml
No issues are reported now.
Thanks
Please review.
- Status changed to Needs work
about 1 year ago 6:02am 13 December 2023 - 🇵🇭Philippines clarkssquared
Hi
I applied the MR !3 but there are still many issues that needs to be resolved
➜ config_token git:(8.x-1.6) curl https://git.drupalcode.org/project/config_token/-/merge_requests/3.diff | patch -p 1 % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 8744 0 8744 0 0 14779 0 --:--:-- --:--:-- --:--:-- 14972 patching file 'src/Form/AllowedConfigTokensForm.php' patching file 'src/Form/ConfigTokensForm.php' patching file 'tests/src/Functional/ConfigTokenAdminUi.php' patching file 'tests/src/Functional/ConfigTokenBase.php' patching file 'tests/src/Functional/ConfigTokenContent.php' patching file 'tests/src/Functional/ConfigTokenTest.php' ➜ config_token git:(8.x-1.6) ✗ .. ➜ contrib git:(master) ✗ phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml config_token FILE: ...arksubing-subing/Projects/d9/d9-local/web/modules/contrib/config_token/tests/src/Functional/ConfigTokenTest.php --------------------------------------------------------------------------------------------------------------------- FOUND 1 ERROR AFFECTING 1 LINE --------------------------------------------------------------------------------------------------------------------- 6 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is Drupal\Core\Link. --------------------------------------------------------------------------------------------------------------------- PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY --------------------------------------------------------------------------------------------------------------------- FILE: /Users/clarksubing-subing/Projects/d9/d9-local/web/modules/contrib/config_token/config_token.module --------------------------------------------------------------------------------------------------------------------- FOUND 11 ERRORS AND 2 WARNINGS AFFECTING 13 LINES --------------------------------------------------------------------------------------------------------------------- 5 | ERROR | [x] Doc comment short description must start with a capital letter 9 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is | | Drupal\Core\Render\BubbleableMetadata. 29 | ERROR | [x] Short array syntax must be used to define arrays 30 | ERROR | [x] Short array syntax must be used to define arrays 41 | ERROR | [x] Short array syntax must be used to define arrays 43 | WARNING | [x] A comma should follow the last multiline array item. Found: ) 47 | ERROR | [x] Short array syntax must be used to define arrays 48 | ERROR | [x] Short array syntax must be used to define arrays 49 | ERROR | [x] Short array syntax must be used to define arrays 56 | ERROR | [x] Additional blank lines found at end of doc comment 58 | ERROR | [x] Short array syntax must be used to define arrays 67 | WARNING | [ ] Line exceeds 80 characters; contains 89 characters 69 | ERROR | [x] Use null coalesce operator instead of ternary operator. --------------------------------------------------------------------------------------------------------------------- PHPCBF CAN FIX THE 12 MARKED SNIFF VIOLATIONS AUTOMATICALLY --------------------------------------------------------------------------------------------------------------------- FILE: /Users/clarksubing-subing/Projects/d9/d9-local/web/modules/contrib/config_token/README.md ----------------------------------------------------------------------------------------------- FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 4 LINES ----------------------------------------------------------------------------------------------- 21 | WARNING | Line exceeds 80 characters; contains 87 characters 29 | WARNING | Line exceeds 80 characters; contains 107 characters 30 | WARNING | Line exceeds 80 characters; contains 91 characters 33 | WARNING | Line exceeds 80 characters; contains 134 characters ----------------------------------------------------------------------------------------------- FILE: /Users/clarksubing-subing/Projects/d9/d9-local/web/modules/contrib/config_token/src/Form/ConfigTokensForm.php --------------------------------------------------------------------------------------------------------------------- FOUND 1 ERROR AFFECTING 1 LINE --------------------------------------------------------------------------------------------------------------------- 6 | ERROR | [x] Use statements should be sorted alphabetically. The first wrong one is | | Drupal\Core\Form\ConfigFormBase. --------------------------------------------------------------------------------------------------------------------- PHPCBF CAN FIX THE 1 MARKED SNIFF VIOLATIONS AUTOMATICALLY --------------------------------------------------------------------------------------------------------------------- Time: 341ms; Memory: 10MB ➜ contrib git:(master) ✗
moving this to needs work
- First commit to issue fork.
- Status changed to Needs review
about 1 year ago 6:48am 13 December 2023 - 🇬🇧United Kingdom marcelovani London
PR looks good, pls confirm that everything still works as expected and we can merge.
- thakurnishant_06 India
Hi @marcelovani,
I have tested the MR3 against the dev build, patch applies cleanly and it successfully resolves all code style errors /warnings. Everything is working as expected. I recommend moving it to RTBC .