sonarr-repo-only/frontend/gulp/copy.js

43 lines
1.1 KiB
JavaScript
Raw Normal View History

const path = require('path');
const gulp = require('gulp');
const print = require('gulp-print').default;
const cache = require('gulp-cached');
const livereload = require('gulp-livereload');
const paths = require('./helpers/paths.js');
2018-01-13 02:01:27 +00:00
gulp.task('copyHtml', () => {
2019-03-23 02:07:35 +00:00
return gulp.src(paths.src.html, { base: paths.src.root })
2018-01-13 02:01:27 +00:00
.pipe(cache('copyHtml'))
.pipe(print())
.pipe(gulp.dest(paths.dest.root))
.pipe(livereload());
});
gulp.task('copyFonts', () => {
return gulp.src(
2019-03-23 02:07:35 +00:00
path.join(paths.src.fonts, '**', '*.*'), { base: paths.src.root }
2018-01-13 02:01:27 +00:00
)
.pipe(cache('copyFonts'))
.pipe(print())
.pipe(gulp.dest(paths.dest.root))
2018-01-13 02:01:27 +00:00
.pipe(livereload());
});
gulp.task('copyImages', () => {
return gulp.src(
2019-03-23 02:07:35 +00:00
path.join(paths.src.images, '**', '*.*'), { base: paths.src.root }
2018-01-13 02:01:27 +00:00
)
.pipe(cache('copyImages'))
.pipe(print())
.pipe(gulp.dest(paths.dest.root))
2018-01-13 02:01:27 +00:00
.pipe(livereload());
});
2020-12-31 21:11:22 +00:00
gulp.task('copyRobots', () => {
return gulp.src(paths.src.robots, { base: paths.src.root })
.pipe(cache('copyRobots'))
.pipe(print())
.pipe(gulp.dest(paths.dest.root))
.pipe(livereload());
});