Skip to content

Commit

Permalink
adding a dist-product task and a /dist cleanup task
Browse files Browse the repository at this point in the history
  • Loading branch information
holger1411 committed Jan 27, 2017
1 parent 4620126 commit 2b8a2f9
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,25 @@ gulp.task('copy-assets', function() {
// Run
// gulp dist
// Copies the files to the /dist folder for distributon
gulp.task('dist', function() {
gulp.src(['**/*','!sass','!sass/**','!bower_components','!bower_components/**','!node_modules','!node_modules/**','!src','!src/**','!dist','!bower.json', '!gulpfile.js', '!package.json', '*'])
gulp.task('dist', ['clean-dist'], function() {
gulp.src(['**/*','!bower_components','!bower_components/**','!node_modules','!node_modules/**','!src','!src/**','!dist','!dist/**','!sass','!sass/**','!readme.txt','!readme.md','!package.json','!gulpfile.js','!CHANGELOG.md','!.travis.yml','!jshintignore', '!codesniffer.ruleset.xml', '*'])
.pipe(gulp.dest('dist/'))
});

// Deleting any file inside the /src folder
gulp.task('clean-dist', function () {
return del(['dist/**/*',]);
});

// Run
// gulp dist-product
// Copies the files to the /dist folder for distributon
gulp.task('dist-product', ['clean-dist-product'], function() {
gulp.src(['**/*','!bower_components','!bower_components/**','!node_modules','!node_modules/**','!src','!src/**','!dist','!dist/**', '*'])
.pipe(gulp.dest('dist-product/'))
});

// Deleting any file inside the /src folder
gulp.task('clean-dist-product', function () {
return del(['dist-product/**/*',]);
});

0 comments on commit 2b8a2f9

Please sign in to comment.