Files: a7d2b57bd7389bb5f918f2e92437805906c3b682 / gulpfile.js
714 bytesRaw
1 | var gulp = require('gulp'); |
2 | var minifyHtml = require('gulp-minify-html'); |
3 | var cleanCSS = require('gulp-clean-css'); |
4 | var usemin = require('gulp-usemin'); |
5 | var rev = require('gulp-rev'); |
6 | var ghPages = require('gulp-gh-pages'); |
7 | |
8 | var ghPagesConfig = { |
9 | branch: 'master' |
10 | }; |
11 | |
12 | gulp.task('build', function () { |
13 | return gulp.src('src/index.html') |
14 | .pipe(usemin({ |
15 | css: [ rev() ], |
16 | html: [ minifyHtml({ empty: true }) ], |
17 | inlinecss: [ cleanCSS, 'concat' ] |
18 | })) |
19 | .pipe(gulp.dest('dist/')); |
20 | }); |
21 | |
22 | gulp.task('publish', function() { |
23 | return gulp.src('./dist/**/*') |
24 | .pipe(ghPages({ |
25 | branch: 'master' |
26 | })); |
27 | }); |
28 | |
29 | gulp.task('deploy', ['build'], function () { |
30 | return gulp.start('publish'); |
31 | }); |
Built with git-ssb-web