Closed (fixed)
Project:
Config Snapshot
Version:
2.0.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
29 Oct 2024 at 05:08 UTC
Updated:
2 Jan 2025 at 21:24 UTC
Jump to comment: Most recent
The current main branch 2.0.x has a gitlab pipeline that uses the PHPCS tool to find problems in this repository's coding style. At the moment the tool is being ignored.
Go to https://git.drupalcode.org/project/config_snapshot/-/jobs/2780334
See
$ vendor/bin/phpcs -s $_WEB_ROOT/modules/custom --report-junit=junit.xml --report-full --report-summary --report-source $_PHPCS_EXTRA
FILE: ...t/web/modules/custom/config_snapshot/src/ConfigSnapshotServiceProvider.php
--------------------------------------------------------------------------------
FOUND 4 ERRORS AND 1 WARNING AFFECTING 4 LINES
--------------------------------------------------------------------------------
46 | ERROR | [x] Expected newline after closing brace
| | (Drupal.ControlStructures.ControlSignature.NewlineAfterCloseBrace)
47 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
| | (Drupal.Commenting.InlineComment.InvalidEndChar)
51 | ERROR | [x] Expected newline after closing brace
| | (Drupal.ControlStructures.ControlSignature.NewlineAfterCloseBrace)
52 | WARNING | [ ] Line exceeds 80 characters; contains 83 characters
| | (Drupal.Files.LineLength.TooLong)
52 | ERROR | [x] Inline comments must end in full-stops, exclamation marks,
| | question marks, colons, or closing parentheses
| | (Drupal.Commenting.InlineComment.InvalidEndChar)
--------------------------------------------------------------------------------
PHPCBF CAN FIX THE 4 MARKED SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
Time: 157ms; Memory: 6MB
PHP CODE SNIFFER REPORT SUMMARY
--------------------------------------------------------------------------------
FILE ERRORS WARNINGS
--------------------------------------------------------------------------------
...ustom/config_snapshot/src/ConfigSnapshotServiceProvider.php 4 1
--------------------------------------------------------------------------------
A TOTAL OF 4 ERRORS AND 1 WARNING WERE FOUND IN 7 FILES
--------------------------------------------------------------------------------
PHPCBF CAN FIX 4 OF THESE SNIFF VIOLATIONS AUTOMATICALLY
--------------------------------------------------------------------------------
PHP CODE SNIFFER VIOLATION SOURCE SUMMARY
---------------------------------------------------------------------------
SOURCE COUNT
---------------------------------------------------------------------------
[x] Drupal.Commenting.InlineComment.InvalidEndChar 2
[x] Drupal.ControlStructures.ControlSignature.NewlineAfterCloseBrace 2
[ ] Drupal.Files.LineLength.TooLong 1
---------------------------------------------------------------------------
A TOTAL OF 5 SNIFF VIOLATIONS WERE FOUND IN 3 SOURCES
---------------------------------------------------------------------------
PHPCBF CAN FIX THE 2 MARKED SOURCES AUTOMATICALLY (4 VIOLATIONS IN TOTAL)
---------------------------------------------------------------------------
Address the CODE SNIFFER VIOLATIONs
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 #2
rohan_singh commentedI am working on this.
Comment #4
rohan_singh commentedHi @trackleft2, I have raised an MR.
Please review.
Thanks
Rohan Singh
Comment #5
joegraduateLGTM. Thanks @rohan_singh!
Comment #7
joegraduateMerged.