Re: [gentoo-dev] escaping variables in sed expressions

2008-04-16 Thread Ciaran McCreesh
On Wed, 16 Apr 2008 19:17:51 +0200 Frank Gruellich [EMAIL PROTECTED] wrote: I was not able to create a filename or path containing it. (Anyone else?) Unix file names can't contain / or null. Unfortunately that stupid sed does not work with \x00 as delimiter... Nor do most Unix apps, since

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-16 Thread Frank Gruellich
* Marius Mauch [EMAIL PROTECTED] 15. Apr 08: On Tue, 15 Apr 2008 16:17:54 +0200 Frank Gruellich [EMAIL PROTECTED] wrote: * Santiago M. Mola [EMAIL PROTECTED] 15. Apr 08: On Tue, Apr 15, 2008 at 1:14 PM, Marijn Schouten (hkBst) Currently is use ':' as sed delimiter when paths are

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Santiago M. Mola
On Tue, Apr 15, 2008 at 1:14 PM, Marijn Schouten (hkBst) [EMAIL PROTECTED] wrote: Hi list, it seems I have been using some fragile sed expression and I'd like to tap the collective wisdom for avoiding doing that in the future. dev-scheme/slib-3.1.5-r1 currently does sed s_prefix =

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Fabian Groffen
On 15-04-2008 13:05:26 +0200, Santiago M. Mola wrote: On Tue, Apr 15, 2008 at 1:14 PM, Marijn Schouten (hkBst) [EMAIL PROTECTED] wrote: Hi list, it seems I have been using some fragile sed expression and I'd like to tap the collective wisdom for avoiding doing that in the future.

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread David Leverton
On Tuesday 15 April 2008 12:14:57 Marijn Schouten (hkBst) wrote: There are several option to handle this. I could use a less common delimiter or I could escape it: ${D//_/\_} instead of ${D}. I could use a sed expression that doesn't suffer from this problem (thanks to dleverton): sed -ne

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Ulrich Mueller
On Tue, 15 Apr 2008, Marijn Schouten (hkBst) wrote: There are several option to handle this. I could use a less common delimiter or I could escape it: ${D//_/\_} instead of ${D}. I could use a sed expression that doesn't suffer from this problem (thanks to dleverton): sed -ne '\_^prefix =

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Frank Gruellich
* Santiago M. Mola [EMAIL PROTECTED] 15. Apr 08: On Tue, Apr 15, 2008 at 1:14 PM, Marijn Schouten (hkBst) Currently is use ':' as sed delimiter when paths are involved. I'd also like to hear from you about proper delimiters if you think ':' is not safe enough. AFAIK, the only corner case

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Petteri Räty
Marijn Schouten (hkBst) kirjoitti: Hi list, it seems I have been using some fragile sed expression and I'd like to tap the collective wisdom for avoiding doing that in the future. dev-scheme/slib-3.1.5-r1 currently does sed s_prefix = /usr/local/_prefix = ${D}/usr/_ -i Makefile to make it

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Marius Mauch
On Tue, 15 Apr 2008 16:17:54 +0200 Frank Gruellich [EMAIL PROTECTED] wrote: * Santiago M. Mola [EMAIL PROTECTED] 15. Apr 08: On Tue, Apr 15, 2008 at 1:14 PM, Marijn Schouten (hkBst) Currently is use ':' as sed delimiter when paths are involved. I'd also like to hear from you about proper

Re: [gentoo-dev] escaping variables in sed expressions

2008-04-15 Thread Mike Frysinger
On Tuesday 15 April 2008, Marijn Schouten (hkBst) wrote: Hi list, it seems I have been using some fragile sed expression and I'd like to tap the collective wisdom for avoiding doing that in the future. dev-scheme/slib-3.1.5-r1 currently does sed s_prefix = /usr/local/_prefix = ${D}/usr/_