update md2site

This commit is contained in:
dntzhang 2017-03-03 12:41:11 +08:00
parent 1beab96976
commit ff61867d94
2 changed files with 5 additions and 8 deletions

View File

@ -7,9 +7,9 @@ var del = require('del'),
rev = require('gulp-rev'),
revCollector = require('gulp-rev-collector'),
header = require('gulp-header'),
cdnReplace = require('gulp-cdn-replace2'),
browserSync = require('browser-sync').create(),
config = require('./project.js');
config = require('./project.js'),
urlPrefix = require('gulp-html-url-prefix');
var assets = [],
cdn = config.cdn,
@ -102,11 +102,8 @@ gulp.task('replace', function() {
gulp.task('cdnReplace', function() {
return gulp.src('./dist/*.html')
.pipe(cdnReplace({
dir: './dist',
root: {
css: cdn
}
.pipe(urlPrefix({
prefix: cdn
}))
.pipe(gulp.dest('./dist'));
});

View File

@ -18,10 +18,10 @@
"browser-sync": "^2.18.6",
"del": "^2.2.2",
"gulp": "^3.9.1",
"gulp-cdn-replace2": "^0.6.1",
"gulp-csso": "^2.0.0",
"gulp-header": "^1.8.8",
"gulp-html-replace": "^1.6.2",
"gulp-html-url-prefix": "^0.1.1",
"gulp-rev": "^7.1.2",
"gulp-rev-collector": "^1.1.1",
"html-webpack-plugin": "^2.26.0",