patches vs sed

Seth W. Klein sk at sethwklein.net
Sun Sep 22 07:43:32 PDT 2002


Greg Schafer <gschafer at zip.com.au> wrote:
> 
> <trim>
> 
> Simple seds are fine.
> Complex seds should be replaced with patches.
> 
> What prompted me to write this was the latest man commands:-
> 
> sed -e '/^PAGER/s/-is/-isR/' \
>     -e 's%MANPATH[[:space:]]/usr/man%#MANPATH /usr/man%' \
>     src/man.conf.backup > src/man.conf &&
> 
> That is bordering on complex and could likely be replaced with a patch.
> 
> Just MHO of course.

I agree. Setting a sed like this loose in something i'm going to
install frightens me. A patch, i can trust. If i read it, i know
exactly what it will do.

cheers,
Seth W. Klein
-- 
sk at sethwklein.net                             http://www.sethwklein.net/
Maintainer, LFS FAQ                 http://www.linuxfromscratch.org/faq/
-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-dev' in the subject header of the message



More information about the lfs-dev mailing list