Specifically, I want to run
lsyncd lsyncd.lua
And
webpack --progress --color -w
Which are both long-running processes. I want to see the output from both, interlaced in my terminal. It doesn't matter if the results are a bit jumbled, I just like to see that they're doing what they're supposed to.
Also, I want it to kill both processes when I press Ctrl+C
.
I'm trying
parallel ::: 'lsyncd lsyncd.lua' 'webpack --progress --color -w'
which seems to be working, but I can't see any output even though when I run those commands individually, they output something.
Best Answer
Using
parallel
(in themoreutils
package):Since the
parallel
process runs in the foreground, hitting CTRL+C will terminate all the processes running on top of it at once.-j
: Use to limit the number of jobs that are run at the same time;--
: separates the options from the commands.