CE Add error string formatter for stylelint
What does this MR do?
EE port: https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/9782
In https://gitlab.com/gitlab-org/gitlab-ce/issues/58362 we noticed we had to grep for ✖
to find errors in a list of
warnings.
https://gitlab.com/lbennett/stylelint-error-string-formatter uses the upstream provided stringFormatter
and appends a re-print of all errors.
Example output from this evenings offending commit
app/assets/stylesheets/pages/status.scss
41:4 ⚠ Selector should be written in lowercase with hyphens selector-class-pattern
42:4 ⚠ Selector should be written in lowercase with hyphens selector-class-pattern
app/assets/stylesheets/pages/todos.scss
120:9 ⚠ Expected nesting depth to be no more than 3 max-nesting-depth
124:9 ⚠ Expected nesting depth to be no more than 3 max-nesting-depth
app/assets/stylesheets/pages/tree.scss
125:9 ⚠ Expected nesting depth to be no more than 3 max-nesting-depth
134:9 ⚠ Expected nesting depth to be no more than 3 max-nesting-depth
app/assets/stylesheets/pages/wiki.scss
25:3 ⚠ Expected a placeholder selector (e.g. %placeholder) to be used in @extend scss/at-extend-no-missing-placeholder
FAILURES:
app/assets/stylesheets/framework/spinner.scss
✖ number-leading-zero 2:30 Expected a leading zero (number-leading-zero)
✖ number-leading-zero 28:23 Expected a leading zero (number-leading-zero)
What are the relevant issue numbers?
Does this MR meet the acceptance criteria?
-
Changelog entry added, if necessary -
Documentation created/updated via this MR -
Documentation reviewed by technical writer or follow-up review issue created -
Tests added for this feature/bug -
Tested in all supported browsers -
Conforms to the code review guidelines -
Conforms to the merge request performance guidelines -
Conforms to the style guides -
Conforms to the database guides -
Link to e2e tests MR added if this MR has Requires e2e tests label. See the Test Planning Process. -
Security reports checked/validated by reviewer
Edited by Luke Bennett