start multiple bash processes and wait for all to complete
#!/bin/bash
FAIL=0
echo "starting"
./sleeper 2 0 &
./sleeper 2 1 &
./sleeper 3 0 &
./sleeper 2 0 &
for job in `jobs -p`
do
echo $job
wait $job || let "FAIL+=1"
done
echo $FAIL
if [ "$FAIL" == "0" ];
then
echo "YAY!"
else
echo "FAIL! ($FAIL)"
fi
Also in Shell:
- remove home icon ubuntu
- bash get kernel version
- ubuntu bluetooth not turning on
- webpack uninstall npm
- where is path on klai linux
- undo last commit
- git merge branch to master
- firewall status on ubuntu
- compare local git branch with remote
- grep for all .py files containing a word
- how to move file in directory in linux
- how to check which packages homebrew has installed
- npm move package from devdependencies to dependencies
- git reset remote
- install pygame
- how to know partition of current directory
- add-apt-repository
- mac docker ubuntu image
- kubernetes copy files to persistent volume
- How to find cmake version in ubuntu?
- git take ours
- install itertools
- find exclude hidden files
- how to get out of git og