Re: Sort the file
From: Barry Margolin (barmar_at_alum.mit.edu)
Date: 04/29/04
- Next message: Barry Margolin: "Re: adding leading characters to stdout"
- Previous message: William Park: "Re: adding leading characters to stdout"
- In reply to: Charles Demas: "Re: Sort the file"
- Next in thread: Chris F.A. Johnson: "Re: Sort the file"
- Reply: Chris F.A. Johnson: "Re: Sort the file"
- Reply: Søren Hansen: "Re: Sort the file"
- Reply: Kevin Rodgers: "Re: Sort the file"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 29 Apr 2004 02:25:40 -0400
In article <c6pn28$7up$1@pcls3.std.com>,
demas@TheWorld.com (Charles Demas) wrote:
> untested
>
> grep -n infile | sort -k 2.1,2.1 1n | awk '{print $2}'
Aren't you missing an argument to grep -- the regexp? I guess you meant
grep -n '.*' infile | ...
But that seems like a strange way to do what "cat -n infile" can do.
-- Barry Margolin, barmar@alum.mit.edu Arlington, MA *** PLEASE post questions in newsgroups, not directly to me ***
- Next message: Barry Margolin: "Re: adding leading characters to stdout"
- Previous message: William Park: "Re: adding leading characters to stdout"
- In reply to: Charles Demas: "Re: Sort the file"
- Next in thread: Chris F.A. Johnson: "Re: Sort the file"
- Reply: Chris F.A. Johnson: "Re: Sort the file"
- Reply: Søren Hansen: "Re: Sort the file"
- Reply: Kevin Rodgers: "Re: Sort the file"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|