A
A
Anima-ana2019-01-17 18:53:50
gulp.js
Anima-ana, 2019-01-17 18:53:50

Why did Gulp stop building the dist folder?

Hello. I recently started learning gulp here on this article https://webdesign-master.ru/blog/tools/2016-03-09-... I set everything up, the project was going perfectly. Then I did not open the project for a long time and when I returned to it, I saw that it had stopped collecting the dist folder. All tasks work, there are no errors in the console.
Here is a piece:

gulp.task('build', ['clean', 'img', 'sass', 'scripts'], function() {

    var buildCss = gulp.src([ // Переносим библиотеки в продакшен
        'app/css/style.css',
        'app/css/libs.min.css'
        ])
    .pipe(gulp.dest('dist/css'))

    var buildFonts = gulp.src('app/fonts/**/*') // Переносим шрифты в продакшен
    .pipe(gulp.dest('dist/fonts'))

    var buildJs = gulp.src('app/js/**/*') // Переносим скрипты в продакшен
    .pipe(gulp.dest('dist/js'))

    var buildHtml = gulp.src('app/*.html') // Переносим HTML в продакшен
    .pipe(gulp.dest('dist'));

});

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anima-ana, 2019-01-18
@Anima-ana

I found the problem by calling the tasks separately. At first, scss stopped compiling for me, it turned out that because of the autoprefixer. and nothing was created in dist because 'build' was not specified in this line . It is strange that when I did everything according to the lesson for the first time, everything was ok. gulp.task('default', ['build', 'watch']);

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question