lint-staged
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -0,1 +1,7 @@ | ||
# 2.0.2 | ||
- Fixes an error when running a config with just one task (#28). #27 @Anber. | ||
- Beautiful string representation for multiple linters in case of error. | ||
- Added tests to getLintersAsString. | ||
# 2.0.1 | ||
@@ -2,0 +8,0 @@ |
{ | ||
"name": "lint-staged", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "Lint files staged by git", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -8,2 +8,3 @@ var sgf = require('staged-git-files') | ||
var runScript = require('./runScript') | ||
var getLintersAsString = require('./getLintersAsString') | ||
@@ -27,3 +28,3 @@ var defaultLinters = {} | ||
if (fileList.length) { | ||
spinner.text = 'Running ' + Array.isArray(linter) ? linter.join(' → ') : linter + '...' | ||
spinner.text = 'Running ' + getLintersAsString(linter) + '...' | ||
runScript(linter, fileList, config, function (error, exitCode) { | ||
@@ -34,3 +35,6 @@ if (error) { | ||
if (exitCode > 0) { | ||
console.log('😱 %s found some issues. Fix them and try again.', linter, exitCode) | ||
console.log( | ||
'😱 %s found some issues. Fix them and try again.', | ||
getLintersAsString(linter) | ||
) | ||
} | ||
@@ -37,0 +41,0 @@ spinner.stop() |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
21035
18
305