On Sun, 25 Nov 2007 20:40:08 -0600, [EMAIL PROTECTED] wrote:
Yup, both of those should work from cron or anywhere. In my case and
probably many other as well, I could shorten the ps approach to:
ps aux|grep '[X] :0'
Or use pidof X.
--
Neil Bothwick
Top Oxymorons Number 46: Found missing
Neil Bothwick [EMAIL PROTECTED] writes:
pidof X
Vey nice ...
Neil are those green bananas on your head or leaves?
--
[EMAIL PROTECTED] mailing list
Andrey Falko [EMAIL PROTECTED] writes:
How about something like this: retval=`ps aux | grep tty | grep X | awk
'{print $2}'`
Or retval=`cat /tmp/.X0-lock`
Or even better:
if [[ -e /tmp/.X0-lock ]];then
Yup, both of those should work from cron or anywhere. In my case and
probably many
On Sun, Nov 25, 2007 at 08:40:08PM -0600, [EMAIL PROTECTED] wrote:
Yup, both of those should work from cron or anywhere. In my case and
probably many other as well, I could shorten the ps approach to:
ps aux|grep '[X] :0'
But looking for /tmp/.X0-lock is probably the most reliable. Thanks
4 matches
Mail list logo