X-Spam-Check-By: sourceware.org To: cygwin AT cygwin DOT com From: Matthew Woehlke Subject: Re: display ps command line parameters Date: Mon, 30 Apr 2007 12:47:57 -0500 Lines: 23 Message-ID: References: <4edba06c76Andy AT jet-net DOT co DOT uk> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.10) Gecko/20070221 Thunderbird/1.5.0.10 Mnenhy/0.7.4.0 In-Reply-To: X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Tony Richardson wrote: > Andy Jet-Net 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/