diff --git a/.gitignore b/.gitignore index 3c3629e..20cbfc5 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ node_modules +cdn diff --git a/Gulpfile.js b/Gulpfile.js index 9ecfc22..6e31497 100644 --- a/Gulpfile.js +++ b/Gulpfile.js @@ -4,6 +4,7 @@ let cleanCSS = require('gulp-clean-css'); let uglify = require('gulp-uglify'); let concat = require('gulp-concat'); let gulpCopy = require('gulp-copy'); +let RevAll = require('gulp-rev-all'); gulp.task('styles', () => { return gulp.src([ @@ -44,5 +45,13 @@ gulp.task('copy:html', () => { .pipe(gulp.dest('dist')) }) +// Experimental +gulp.task('cdn', () => { + return gulp + .src('dist/**') + .pipe(RevAll.revision({ dontRenameFile: ['.html', '.png', '.svg', '.jpeg', '.jpg']})) + .pipe(gulp.dest('cdn')); +}) + gulp.task('copy', ['copy:images', 'copy:html', 'copy:fonts']) gulp.task('build', ['styles', 'scripts', 'copy']); diff --git a/dist/index.html b/dist/index.html index 79f53a2..d240020 100644 --- a/dist/index.html +++ b/dist/index.html @@ -554,22 +554,7 @@ - @@ -587,6 +572,21 @@ window.addEventListener('scroll', function(e) { + \ No newline at end of file diff --git a/package.json b/package.json index e8c1f86..06a9015 100644 --- a/package.json +++ b/package.json @@ -21,6 +21,7 @@ "gulp-clean-css": "^3.9.0", "gulp-concat": "^2.6.1", "gulp-copy": "^1.0.1", + "gulp-rev-all": "^0.9.7", "gulp-uglify": "^3.0.0" } }