This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: display ps command line parameters


Tony Richardson wrote:
Andy <at> Jet-Net <Andy <at> jet-net.co.uk> writes:
In "ps -s" I get something like:

 PID  TTY    STIME COMMAND
1234  con 09:00:00 /path/program

Is there a way of doing this through ps (or an alternative) in Cygwin?

An alternative would be to parse /proc/PID/cmdline. Arguments are separated by null bytes.

cat /proc/$pid/cmdline | xargs -0 echo


um... and since Cygwin has this information, doesn't this mean that 'ps' is missing a feature that is standard to pretty much every other *nix implementation of 'ps'? (I don't have a POSIX standard handy, but I wonder if this is an unnecessary POSIX violation?)

--
Matthew
If you believe you received this e-mail in error, you are probably sadly mistaken, but if not, aren't you lucky?



-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]