Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com
From: "Brian Warn" <bwarn-nm@seattletimes.com>
To: <cygwin@cygwin.com>
Subject: RE: ps within DOS
Date: Fri, 29 Mar 2002 14:55:38 -0800
Message-ID: <D4AE310621B50E4393EFE060F52D414CA886C9@EXCHANGE2.seatimes.com>
MIME-Version: 1.0
Content-Type: text/plain;
	charset="US-ASCII"
Content-Transfer-Encoding: 7bit
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
In-Reply-To: <D4AE310621B50E4393EFE060F52D414C0F655B@EXCHANGE2.seatimes.com>
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2600.0000
Importance: Normal

I suppose that I could run this under cygwin's perl ...

-----Original Message-----
From: Brian Warn [mailto:bwarn-nm@seattletimes.com] 
Sent: Friday, March 29, 2002 2:54 PM
To: 'cygwin@cygwin.com'
Subject: ps within DOS


As part of a (win32) perl program I'm running, I'm trying to run a
system ps command and return to the DOS shell (or whatever the shell is
known as in Win2K).  From the command line, I can do the following, but
I stay in the bash shell:

C:> c:\cygwin\cygwin.bat | ps | exit

[ ps info here ]

my_machine $


The bottom line is that I want to read process info into an array as
follows:

@my_array=`cygwin.bat | ps | grep "desired string"`;

Any help is appreciated!

Thanks,
Brian


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

