How to start an app by a terminal and to keep it running, when closing the terminal?
Richard Hector
richard at walnut.gen.nz
Wed May 21 02:49:31 UTC 2014
On 21/05/14 09:30, Ralf Mardorf wrote:
> Why is evolution launched, while "evowrap --force-shutdown" and "evoterm --force-shutdown" are running?
>
> case $1 in
> JWM) evoterm --force-shutdown
> while ps aux | grep "evowrap --force-shutdown" | grep -v grep ; do sleep 1 ; done
> while ps aux | grep "evoterm --force-shutdown" | grep -v grep ; do sleep 1 ; done
> evolution
> exit;;
> esac
Have you confirmed that the grep is accurately finding the ps result?
Note you could be using:
pgrep --full "evowrap --force-shutdown"
or similar.
Also, rather than using "grep -v grep", you could use
grep "[e]voterm"
which will match "evoterm" but will never match itself.
Richard
PS what makes this OT?
More information about the D-community-offtopic
mailing list