Re: bash: finding if mozilla is running

From: Alan Connor (alanconnor_at_earthlink.net)
Date: 07/26/03

  • Next message: J. Zidar: "Cannot connect to http://localhost:631"
    Date: Sat, 26 Jul 2003 07:36:47 -0700
    To: debian-user@lists.debian.org
    
    

    > From seneca-cunningham@rogers.com Sat Jul 26 07:35:08 2003
    >
    >
    >
    >
    > On Sat, Jul 26, 2003 at 10:22:53AM +0100, David selby wrote:
    > > Writting a small script to make mozilla show the results of HTML code=20
    > > written in vi, when vi saves, the script automaticly changes mozilla to=
    > =20
    > > show that HTML.
    > >=20
    > > I need to know if mozilla is running, if not I need to call it first ...=
    > =20
    > > seemed simple
    > >=20
    > > if ! ps ax | grep "mozilla-bin" &>/dev/null; then
    > > /usr/local/mozilla/mozilla -P web &
    > > .....
    > [...]
    > > Ie its picking up on the grep process, finding "mozilla-bin", saying yep=
    > =20
    > > its running, dont call mozilla & bang, script fails.
    >
    > ps --no-headers -C "mozilla-bin" | grep -q -- "-bin"
    >

    This might help in the future, Seneca:

    ps a | grep slrn | grep -v grep
      863 pts/3 S 0:00 slrn

    Alan

    -- 
    To UNSUBSCRIBE, email to debian-user-request@lists.debian.org 
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
    

  • Next message: J. Zidar: "Cannot connect to http://localhost:631"

    Relevant Pages

    • Re: Lady Godiva
      ... DNB dates the letters to 1028-1029 based on a determination of the churchmen's overlapping years. ... brothers named Alan 'the Red' and Alan 'the Black'. ... See the record for Alan 'the Red' and his 2 brothers at Doyle's 'Official ... To unsubscribe from the list, ...
      (soc.genealogy.medieval)
    • Re: still in search of a good news reader
      ... I know you asked about GUI stuff, but slrn does everything I've ever wanted. ... news.gmane.org which normally displays my posts within a few minutes fouled up just with Debian-user and not with other lists or groups I use, delaying posts about 24 hours. ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx with a subject of "unsubscribe". ...
      (Debian-User)
    • Re: Bad news from my ophthalmologist: Macular edema and retinopathy. .
      ... Alan S wrote: ... to unsubscribe to ASD. ... please) posting 2 new messages to the thread!!!! ...
      (alt.support.diabetes)
    • Re: slrn crash -- froze everything
      ... I got suggested a hard drive problem, ... A few days ago I tried to start slrn with a different news-server (one ... any clues for chasing down the source of these ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx ...
      (Debian-User)
    • Re: 2.6.17.6 i810 + drm:810_wait_ring - kernel crash, help?
      ... Alan, you seemed to have worked with this issue before? ... Any idea to its root cause? ... On Mon, 28 Aug 2006, Justin Piszcz wrote: ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx with a subject of "unsubscribe". ...
      (Linux-Kernel)