Skip to content

EE Add error string formatter for stylelint

Luke Bennett requested to merge ee-add-stylelint-error-string-formatter into master

What does this MR do?

CE: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/25668

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?

Edited by Luke Bennett

Merge request reports