Commit e5842581 authored by Jacek Lebioda's avatar Jacek Lebioda
Browse files

Updated gulp file to stop using deprecated features. The versions are locked

parent 35a86a62
Pipeline #8101 passed with stage
in 1 minute and 6 seconds
......@@ -2,7 +2,8 @@ var gulp = require('gulp'),
gulp_uglify = require('gulp-uglify'),
gulp_clean_css = require('gulp-clean-css'),
gulp_concat = require('gulp-concat'),
gulp_inject = require('gulp-inject');
gulp_inject = require('gulp-inject'),
merge_stream = require('merge-stream');
var css_path = 'src/*.css',
js_path = 'src/*.js',
......@@ -34,7 +35,7 @@ gulp.task('js', function() {
.pipe(gulp.dest('static'));
});
gulp.task('templates', ['css', 'js', 'png', 'svg'], function() {
gulp.task('templates', function() {
return gulp.src(template_path)
.pipe(gulp_inject(gulp.src('static/*.js', {read:false}), {
transform: function(filepath) {
......@@ -51,12 +52,7 @@ gulp.task('templates', ['css', 'js', 'png', 'svg'], function() {
.pipe(gulp.dest('templates'));
});
gulp.task('watch', function() {
gulp.watch(css_path, ['css']);
gulp.watch(js_path , ['js']);
gulp.watch(png_path , ['png']);
gulp.watch(png_path , ['svg']);
gulp.watch(template_path, ['templates']);
});
gulp.task('default', ['png', 'svg', 'css', 'js', 'templates']);
\ No newline at end of file
gulp.task('default', gulp.series(
gulp.parallel('css', 'js', 'png', 'svg'),
'templates'
));
\ No newline at end of file
{
"devDependencies": {
"gulp": "3.9.1",
"gulp-uglify": "latest",
"gulp-concat": "latest",
"gulp-clean-css": "latest",
"gulp-inject": "latest"
"gulp": "4.0.0",
"gulp-uglify": "3.0.1",
"gulp-concat": "2.6.1",
"gulp-clean-css": "4.0.0",
"gulp-inject": "5.0.2",
"merge-stream": "^1.0.1"
}
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment