can't switch to ' from " in .jscsrc
Stwissel opened this issue · 2 comments
Stwissel commented
We like our JS string to be enclosed in single quotes. So I changed in .jscsrc
the line
"validateQuoteMarks": { "mark": "\"", "escape": true },
to
"validateQuoteMarks": { "mark": "\'", "escape": true },
then build or serve fail on the check-js-style module. Lengthy error below.
What did I miss?
[13:50:30] 'check-js-style' errored after 30 ms
[13:50:30] Error: Unable to load JSCS config file
Unable to load JSCS config file
at Object.parseError (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:55:11)
at Object.parse (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:132:22)
at exports.parse (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:417:53)
at Object.exports.getContent (/Users/stw/Code/justmail/playerNG/node_modules/jscs/lib/cli-config.js:88:31)
at Object.exports.load (/Users/stw/Code/justmail/playerNG/node_modules/jscs/lib/cli-config.js:139:20)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/gulp-jscs/index.js:16:27)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/check-js-style.js:50:101)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at /Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:279:18
at finish (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:21:8)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:60:3)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at Gulp.Orchestrator.start (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:134:8)
at runNextSet (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:86:16)
at runSequence (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:97:2)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/serve.js:98:24)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at Gulp.Orchestrator.start (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:134:8)
at runNextSet (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:86:16)
at runSequence (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:97:2)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/serve.js:94:17)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
[13:50:30] Error in plugin 'run-sequence(check-js-style)'
Message:
Unable to load JSCS config file
Unable to load JSCS config file
Stack:
Error: Unable to load JSCS config file
Unable to load JSCS config file
at Object.parseError (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:55:11)
at Object.parse (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:132:22)
at exports.parse (/Users/stw/Code/justmail/playerNG/node_modules/jsonlint/lib/jsonlint.js:417:53)
at Object.exports.getContent (/Users/stw/Code/justmail/playerNG/node_modules/jscs/lib/cli-config.js:88:31)
at Object.exports.load (/Users/stw/Code/justmail/playerNG/node_modules/jscs/lib/cli-config.js:139:20)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/gulp-jscs/index.js:16:27)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/check-js-style.js:50:101)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at /Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:279:18
at finish (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:21:8)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:60:3)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at Gulp.Orchestrator.start (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:134:8)
at runNextSet (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:86:16)
at runSequence (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:97:2)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/serve.js:98:24)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
at Gulp.Orchestrator._runStep (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:214:10)
at Gulp.Orchestrator.start (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:134:8)
at runNextSet (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:86:16)
at runSequence (/Users/stw/Code/justmail/playerNG/node_modules/run-sequence/index.js:97:2)
at Gulp.<anonymous> (/Users/stw/Code/justmail/playerNG/node_modules/modern-web-dev-build/dist/gulp/tasks/serve.js:94:17)
at module.exports (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/lib/runTask.js:34:7)
at Gulp.Orchestrator._runTask (/Users/stw/Code/justmail/playerNG/node_modules/orchestrator/index.js:273:3)
Stwissel commented
Ohem.... sorry my bad. The line should be:
"validateQuoteMarks": { "mark": "'", "escape": true },
then it works
dsebastien commented
Yep, no need for escaping in that case :)