Skip to content
This repository has been archived by the owner on Jan 31, 2024. It is now read-only.

Commit

Permalink
add an optional callback to the build action
Browse files Browse the repository at this point in the history
  • Loading branch information
spalger committed Nov 17, 2016
1 parent 0e4d4fa commit 6a1012f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tasks/build/build_action.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
module.exports = function (plugin) {
module.exports = function (plugin, callback) {
if (!callback) callback = function () {};

var vfs = require('vinyl-fs');
var zip = require('gulp-zip');
Expand Down Expand Up @@ -78,7 +79,8 @@ module.exports = function (plugin) {
}))

.pipe(zip(`${buildId}.zip`))
.pipe(vfs.dest(join(plugin.root, 'build')));
.pipe(vfs.dest(join(plugin.root, 'build')))
.on('end', callback);
}

main();
Expand Down

0 comments on commit 6a1012f

Please sign in to comment.