Skip to content

Instantly share code, notes, and snippets.

@dmitrylebedev
Last active October 10, 2016 07:26

Revisions

  1. dmitrylebedev revised this gist Oct 10, 2016. 1 changed file with 1 addition and 4 deletions.
    5 changes: 1 addition & 4 deletions gulpfile.js
    Original file line number Diff line number Diff line change
    @@ -1,10 +1,7 @@
    // Локальный сервер
    gulp.task("serve", function() {
    server.init({
    server: "build",
    notify: false,
    open: true,
    ui: false
    server: "build"
    });

    gulp.watch("sass/**/*.{scss,sass}", ["style"]);
  2. dmitrylebedev created this gist Oct 10, 2016.
    19 changes: 19 additions & 0 deletions gulpfile.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,19 @@
    // Локальный сервер
    gulp.task("serve", function() {
    server.init({
    server: "build",
    notify: false,
    open: true,
    ui: false
    });

    gulp.watch("sass/**/*.{scss,sass}", ["style"]);
    gulp.watch("*.html", ["copyhtml"]);
    gulp.watch("build/*.html").on("change", server.reload);
    });

    // Копирует html из корня проекта в папку build
    gulp.task("copyhtml", function() {
    return gulp.src("*.html")
    .pipe(gulp.dest("build/"));
    });