[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Help with sed
From: |
Chet Ramey |
Subject: |
Re: Help with sed |
Date: |
Sat, 17 Apr 2010 20:19:22 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.1.7) Gecko/20100111 Lightning/1.0b1 Thunderbird/3.0.1 |
On 4/17/10 2:23 PM, William Park wrote:
> Key insight would be
>
> content=$(cat $script | sed ...)
> echo "$content" > x
>
> Look at "x", and see what you got. Why not just put all 3 "sed"
> filters in a pipe?
You can do this all with a single sed command and a series of `-e regexp'
options.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU chet@case.edu http://cnswww.cns.cwru.edu/~chet/