Re: perl equivalent of ps

2005-10-16 Thread John W. Krahn
Christopher Spears wrote: > Does Perl have the equivalent of ps in Unix? No. > I've looked in my Programming Perl book, and I could only > find getpgrp, which does the opposit of what I want to > do. Here is a schematic of what I want to accomplish: > > 1) Search ps aux and locate process PROC.

Re: perl equivalent of ps

2005-10-16 Thread Edward WIJAYA
On Sun, 16 Oct 2005 22:14:05 +0800, Christopher Spears <[EMAIL PROTECTED]> wrote: Does Perl have the equivalent of ps in Unix? Check out Proc::ProcessTable module They have nice API for it. or can you try this? perl -e'print `ps --no-header -p$$ -osz`' This is just an example snippet to

perl equivalent of ps

2005-10-16 Thread Christopher Spears
Does Perl have the equivalent of ps in Unix? I've looked in my Programming Perl book, and I could only find getpgrp, which does the opposit of what I want to do. Here is a schematic of what I want to accomplish: 1) Search ps aux and locate process PROC. 2) Get PROC's PID. 3) Use the PID to kill