Im using lerna to run serve
command. this command call vue/cli
which call webpack
to analyze all the files and build the bundle.
So I run lerna run serve --stream
in vue/cli application and I get output of lot of rows in webpack progress:
myapp-vue: <s> [webpack.Progress] 93% asset optimization
myapp-vue: <s> [webpack.Progress] 94% after asset optimization
myapp-vue: <s> [webpack.Progress] 94% after seal
myapp-vue: <s> [webpack.Progress] 95% emitting
myapp-vue: <s> [webpack.Progress] 95% emitting HtmlWebpackPlugin
myapp-vue: <s> [webpack.Progress] 95% emitting vue-cli:pwa-html-plugin
myapp-vue: <s> [webpack.Progress] 95% emitting CopyPlugin
myapp-vue: <s> [webpack.Progress] 95% emitting fork-ts-checker-webpack-plugin
What can I do to not have all the rows? (just to have in one line - every time the line will erase and have new information) and I don't want to lose the webpack progress. maybe to create a buffer for every 3 seconds?
It might be possible to write some kind of debounce-throttle for stdout. Or run gnu-screen with custom config. screen -c ./lerna-screen
But multiview package did the trick for me. It outputs spawned processes to independent columns
npm i multiview -D
{
"name": "root",
"private": true,
"scripts": {
"dev": "multiview [npm run dev:app] [npm run dev:web] -e",
"dev:app": "lerna run dev --stream --no-prefix --ignore=@therobot/*-web",
"dev:web": "lerna run dev --stream --no-prefix --scope=@therobot/*-web"
}
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With