Fix sass-lint

Sass-lint was bumped when gulp-sass-lint was
bumped. This brought in a new version which
changed the interface of `sassLint.format`.

It doesn't look like the `sassLint.format` method
ever defined any arguments or did anything with
the `arguments` variable. That being the case, our
sending it an instance of the 'stylish' ESLint
reporter did nothing in the previous version but
this wasn't obvious because sass-lint defaults to
'stylish' for its output styling.

The latest version (1.4.0) introduced an argument
of a writable stream which, if defined, will be
used to write the output to. This caused a problem
with our sending in the instance of 'stylish'.

This moves the selection of stylish into the
sass-lint config, as described in the
[sass-lint docs](https://github.com/sasstools/gulp-sass-lint/tree/master#sasslintformatwritable).
This commit is contained in:
Tom Byers
2019-04-04 14:44:46 +01:00
parent c3a1e6ed59
commit b83053ddd1

View File

@@ -148,8 +148,10 @@ const lint = {
paths.src + 'stylesheets/components/*.scss',
paths.src + 'stylesheets/views/*.scss',
])
.pipe(plugins.sassLint())
.pipe(plugins.sassLint.format(stylish))
.pipe(plugins.sassLint({
'options': { 'formatter': 'stylish' }
}))
.pipe(plugins.sassLint.format())
.pipe(plugins.sassLint.failOnError());
},
'js': (cb) => {