ttrss/gulpfile.js

32 lines
648 B
JavaScript
Raw Normal View History

2020-09-17 10:30:52 +00:00
// Less configuration
const gulp = require('gulp');
const less = require('gulp-less');
function swallowError(error) {
console.log(error.toString())
this.emit('end')
}
2020-09-17 10:30:52 +00:00
gulp.task('less', function(cb) {
gulp
.src(['themes/compact.less', 'themes/compact_night.less',
'themes/light.less', 'themes/night_blue.less', 'themes/night.less'])
.pipe(less())
.on('error', swallowError)
2020-09-17 10:30:52 +00:00
.pipe(
gulp.dest(function(f) {
return f.base;
})
);
cb();
});
gulp.task(
'default',
gulp.series('less', function(cb) {
gulp.watch(['themes/*.less', 'themes/*/*.less'], gulp.series('less'));
cb();
})
);