2020-02-20 14:38:25 -08:00
|
|
|
|
|
|
|
const { src } = require('gulp');
|
|
|
|
const clean = require('gulp-clean');
|
|
|
|
|
|
|
|
module.exports = exports = function cleanDistribution () {
|
2020-03-06 19:36:09 -08:00
|
|
|
return src([ 'dist', 'rev-manifest.json', 'pages.json', 'assets.json' ], { read: false, allowEmpty: true })
|
2020-02-20 14:38:25 -08:00
|
|
|
.pipe(clean());
|
|
|
|
};
|
|
|
|
|
|
|
|
exports.dev = function cleanDistributionForDev () {
|
2020-03-06 19:36:09 -08:00
|
|
|
return src([ 'dist/**.{js|json|jsx}', 'rev-manifest.json', 'pages.json', 'assets.json' ], { read: false, allowEmpty: true })
|
2020-02-20 14:38:25 -08:00
|
|
|
.pipe(clean());
|
|
|
|
};
|
2020-10-12 15:16:55 -07:00
|
|
|
|
|
|
|
exports.prodBackup = function cleanProdCopy () {
|
|
|
|
return src([ 'published' ], { read: false, allowEmpty: true })
|
|
|
|
.pipe(clean());
|
|
|
|
};
|