Goal
Publishing all my website exactly as it is, after fixing jshint warnings to a new destination.
Issue
While the script files are being transfered and fixmyjs indeed fixes according to its settings, it doesn't fix the missing semicolons.
Code
gulp.task('fix-all-js', function() {
gutil.log(jshint());
return gulp.src(jsDirectoriesSrc)
.pipe(fixmyjs({
asi: false
}))
.pipe(gulp.dest("./dst"));
});
fixmyjs options in package.json
"fixmyjs": {
"camelcase": false,
"curly": false,
"curlyfor": true,
"curlyif": false,
"curlywhile": true,
"debug": true,
"decimals": false,
"eqeqeq": true,
"es3": false,
"hoist": false,
"initUndefined": false,
"invalidConstructor": false,
"invokeConstructors": false,
"isNan": true,
"multivar": false,
"no-comma-dangle": true,
"nonew": false,
"onevar": false,
"parseIntRadix": false,
"plusplus": false,
"rmdelete": false,
"rmempty": true,
"snakecase": false,
"sub": false,
"useLiteral": false
}
also, when I run the following code, I do get the jshint warnings about missing semicolons
gulp.task('jshint', function() {
return gulp.src(jsDirectoriesSrc)
.pipe(jshint())
.pipe(jshint.reporter('jshint-stylish'));
});
Ive tried it on a simple js file with the following code
var b;
if (1 == 1)
b = 1 + 2
else
b = 3 + 5
It fixes the '==' to '===' but no semicolons are added.
Any observations?