[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] multiple program launches with Evolution
- Subject: [ale] multiple program launches with Evolution
- From: fd0man at gmail.com (Michael B. Trausch)
- Date: Thu, 25 Jan 2007 10:14:43 -0500
- In-reply-to: <[email protected]>
- References: <1169696038.20626.3.camel@localhost> <[email protected]>
On Wed, 2007-01-24 at 23:08 -0500, James Sumners wrote:
> Write a script that checks for a running pid and goes from there.
Here is a very simple one that will do the job, at least on my system:
#!/bin/sh
#
# Evolution startup script.
#
EV_PROCESS="evolution --component=mail"
EV_PID_LIST=`ps ax -o pid,command | grep "$EV_PROCESS" | grep -v grep`
if [ "${EV_PID_LIST}" = "" ]; then
exec /usr/bin/evolution
else
EV_PID=$(echo $EV_PID_LIST | cut -f 1 -d' ')
printf "You already have Evolution running (pid %d)!\n" "${EV_PID}"
exit 1
fi
-- Mike
--
Michael B. Trausch
fd0man at gmail.com
Phone: (404) 592-5746
Jabber IM:
fd0man at gmail.com
fd0man at livejournal.com
Demand Freedom! Use open and free protocols, standards, and software!
-------------- next part --------------
An HTML attachment was scrubbed...
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part