Gentoo Archives: gentoo-dev

From: Stephen Bennett <spb@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in media-tv/linuxtv-dvb-apps: ChangeLog linuxtv-dvb-apps-1.1.1.20070924.ebuild
Date: Tue, 25 Sep 2007 22:54:25
Message-Id: 20070926000245.601fa212@maya
In Reply to: Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in media-tv/linuxtv-dvb-apps: ChangeLog linuxtv-dvb-apps-1.1.1.20070924.ebuild by Robert Buchholz
1 On Tue, 25 Sep 2007 11:10:34 +0200
2 Robert Buchholz <rbu@g.o> wrote:
3
4 > I already wondered a while back:
5 > sed only fails if the file does not exist, but not if there was no
6 > replacement. Is there any way to force it to?
7
8 Off the top of my head...
9
10 sed -e '1{x;s/^/0/;x;ta;:a}'
11 -e 's/$STRING/$REPLACEMENT/'
12 -e 'Tb;x;s/^/1/;x;:b;${p;x;/^0/Q1;Q0};'
13 --
14 gentoo-dev@g.o mailing list

Replies