diff --git a/packages/cli/src/commands/plugin/build.ts b/packages/cli/src/commands/plugin/build.ts index 5bb9e171b0..cb28d4cf5f 100644 --- a/packages/cli/src/commands/plugin/build.ts +++ b/packages/cli/src/commands/plugin/build.ts @@ -22,7 +22,7 @@ export default async (cmd: Command) => { if (cmd.watch) { // We're not resolving this promise because watch() doesn't have any exit event. // Instead we just wait until the user sends an interrupt signal. - return new Promise(() => { + await new Promise(() => { const watcher = watch(conf); watcher.on('event', event => { // START — the watcher is (re)starting