[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[ale] scripting foo
- Subject: [ale] scripting foo
- From: jonathan.glass at ibb.gatech.edu (Jonathan Glass)
- Date: Mon Nov 15 18:21:09 2004
- In-reply-to: <1100558992.2837.18.camel@blue>
- References: <1100558992.2837.18.camel@blue>
Quoting Jim Popovitch <jimpop at yahoo.com>:
> I'm looking for some opinions on a better way to do something that I
> currently do as part of a much larger lengthy script. Basically I
> have a program that outputs data in the following format (sans the
> hashed lines):
>
> -----------------------------------
> 5 colors match RGB search:
> red
> yellow
> orange
> blue
> green
> -----------------------------------
>
> Without using perl, and only using common progs (awk,sed,cut,etc), what
> is the most optimized way to return a sorted, left-justified, right-trimmed,
> list of results like this:
>
> -----------------------------------
> blue
> green
> orange
> red
> yellow
> -----------------------------------
>
>
> Tia,
>
> -Jim P.
$ cat foo | grep -v RGB | awk {'print $1;'}
???
Jonathan Glass
-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/