Jonathan Lupa wrote:
>
> Is there a built in command, or shell command to retrieve the process
> name from a pid?
>
> The best I could come up with is slurping the stuff from /proc/cmdline
> or something like ps|cut, but it seems to me there is probably a
> better way I am ignorant of.
>
I wonde
On Tue, Feb 29, 2000 at 03:42:20AM +, Colin Watson wrote:
> [EMAIL PROTECTED] (William T Wilson) wrote:
> >ps ax | awk '$1 == {print $5}'
>
> Or indeed 'ps -o%c h -p '.
Thanks guys! :)
--
[EMAIL PROTECTED]
GPG public key available from http://www.jamdata.net/~jjlupa/gpg.asc
pgp5px2HKSc
[EMAIL PROTECTED] (William T Wilson) wrote:
>On Mon, 28 Feb 2000, Jonathan Lupa wrote:
>> Is there a built in command, or shell command to retrieve the process
>> name from a pid?
>
>ps ax | awk '$1 == {print $5}'
Or indeed 'ps -o%c h -p '. This will probably break on other
Unices (and older vers
On Mon, 28 Feb 2000, Jonathan Lupa wrote:
> Is there a built in command, or shell command to retrieve the process
> name from a pid?
ps ax | awk '$1 == {print $5}'
There's no builtin command to do this. I don't know if Perl can do it or
not. I doubt it, though.
> The best I could come up wit
Is there a built in command, or shell command to retrieve the process
name from a pid?
The best I could come up with is slurping the stuff from /proc/cmdline
or something like ps|cut, but it seems to me there is probably a
better way I am ignorant of.
Thanks!
Jonathan
--
[EMAIL PROTECTED]
GPG p
dave oswald <[EMAIL PROTECTED]> writes:
>
> Normally I would consult with my reference books but am not able to
> get to them.
Or you could just try it! :)
>I thought maybe something like:
>
>$CurrentTime=exec`date "+%D %T"`;
>print $CurrentTime;
>
% perl -e '$CurrentTime = `date "+%D
> I thought maybe something like:
>
> $CurrentTime=exec`date "+%D %T"`;
> print $CurrentTime;
>
$CurrentTime=localtime(time);
Alex Y.
--
_
_( )_
( (o___ +---+
| _ 7 |Alexander Yukhimets|
\(
In a perl script i need to load a variable ($CurrentTime) with the
systems current time. Normally I would consult with my reference books
but am not able to get to them. I find myself using them when I need to
work in perl which is not very often...
I'm looking for time_stamp something like "07/17/
8 matches
Mail list logo