Skip to content

Commit 3eb6c77

Browse files
committed
extended faucetDispatch to report completion of the initial build
this allows independent API consumers to perform operations at the end of the pipeline
1 parent 15c1330 commit 3eb6c77

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ exports.faucetDispatch = async function faucetDispatch(referenceDir, config,
3636
then(buildStep(buckets.scripts.concat(buckets.styles))).
3737
then(buildStep(buckets.markup));
3838
});
39-
runner.run();
39+
let res = runner.run();
4040

4141
if(watch) {
4242
makeWatcher(config.watchDirs, referenceDir).
@@ -55,6 +55,8 @@ exports.faucetDispatch = async function faucetDispatch(referenceDir, config,
5555
} else if(liveserve) {
5656
server.live(liveserve, assetManager.manifest.webRoot);
5757
}
58+
59+
return res; // notifies consumers once the initial build has completed
5860
};
5961

6062
function buildStep(plugins) {

0 commit comments

Comments
 (0)