From: Tanstaafl <tanstaafl@libertytrek.org>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Filter grep output of 'ps aux'
Date: Sat, 03 Mar 2012 08:00:12 -0500 [thread overview]
Message-ID: <4F5215DC.7040904@libertytrek.org> (raw)
In-Reply-To: <CAEH5T2O5G5RQb4+miGbrFwZnFThhyiWqKPvcZTf0FUgREyYRGQ@mail.gmail.com>
On 2012-03-02 4:52 PM, Paul Hartman <paul.hartman+gentoo@gmail.com> wrote:
> On Fri, Mar 2, 2012 at 3:23 PM, Tanstaafl<tanstaafl@libertytrek.org> wrote:
>> Attempt at incorporating your command into this:
>> watch -n1 "ps aux --sort=-%cpu | gawk 'NR==1; $3> 0'"
>>
>> it gives me a syntax error:
>>
>> Every 1.0s: ps aux --sort=-%cpu | gawk 'NR==1;> 0'
>> Fri Mar 2
>> 16:19:01 2012
>>
>> gawk: NR==1;> 0
>> gawk: ^ syntax error
>>
>> Any ideas on how to get this working in the watch version
> Put a backslash before the $, it needs to be escaped in that context.
Aaargh! I could have sworn I tried that... but yes, now it works
perfectly...
Thanks Paul - Gentoo support is the best, even for general linux
questions like this...
next prev parent reply other threads:[~2012-03-03 13:01 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-02 17:46 [gentoo-user] Filter grep output of 'ps aux' Tanstaafl
2012-03-02 17:56 ` Pandu Poluan
2012-03-02 18:03 ` Tanstaafl
2012-03-02 18:12 ` Jason
2012-03-02 18:32 ` Tanstaafl
2012-03-02 19:33 ` Paul Hartman
2012-03-02 20:39 ` Tanstaafl
2012-03-02 20:50 ` Paul Hartman
2012-03-02 21:23 ` Tanstaafl
2012-03-02 21:52 ` Paul Hartman
2012-03-03 13:00 ` Tanstaafl [this message]
2012-03-02 18:02 ` Paul Hartman
2012-03-02 18:12 ` Tanstaafl
2012-03-02 18:30 ` Alan McKinnon
2012-03-02 18:24 ` Pandu Poluan
2012-03-02 19:32 ` Paul Hartman
2012-03-02 19:40 ` [gentoo-user] " Grant Edwards
2012-03-03 2:16 ` Pandu Poluan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F5215DC.7040904@libertytrek.org \
--to=tanstaafl@libertytrek.org \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox