-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathgulpfile.js
28 lines (24 loc) · 830 Bytes
/
gulpfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
var gulp = require('gulp'),
notify = require('gulp-notify'),
del = require('del'),
nunjucksRender = require('gulp-nunjucks-render');
gulp.task('rebuild-method', function() {
return gulp.src('./njk/assets/**/*.*')
.pipe(nunjucksRender({
path: ['./njk/templates'],
inheritExtension: true,
}))
.pipe(gulp.dest('./build'))
});
gulp.task('copy-build', function() {
return gulp.src(['./build/**/*','!./build/.git','!./build/node_modules','!./build/package-lock.json'],{ dot: true }).pipe(gulp.dest('./custom'));
});
gulp.task('rebuild-custom', function() {
return gulp.src('./njk/assets/**/*.*')
.pipe(nunjucksRender({
path: ['./njk/templates'],
inheritExtension: true,
}))
.pipe(gulp.dest('./custom'))
});
gulp.task('build-custom', gulp.series('copy-build', 'rebuild-custom'));