Re: escape characters in sed

2007-05-14 Thread Bob McGowan
Hans du Plooy wrote: william pursell wrote: Your version is missing the final ', so I'm guessing you meant: sed 's/\\)/ /' Yes, sorry, several mistakes on my part... which will replace occurences of \) with a single space Not what I had intended, I just wanted to replace ) with a space.

Re: escape characters in sed

2007-05-14 Thread Alex Samad
On Mon, May 14, 2007 at 08:59:49AM -0700, Bob McGowan wrote: Hans du Plooy wrote: william pursell wrote: Your version is missing the final ', so I'm guessing you meant: sed 's/\\)/ /' Yes, sorry, several mistakes on my part... which will replace occurences of \) with a single space Not

Re: escape characters in sed

2007-05-14 Thread Bob McGowan
Alex Samad wrote: On Mon, May 14, 2007 at 08:59:49AM -0700, Bob McGowan wrote: Hans du Plooy wrote: william pursell wrote: Your version is missing the final ', so I'm guessing you meant: sed 's/\\)/ /' Yes, sorry, several mistakes on my part... which will replace occurences of \) with a

escape characters in sed

2007-05-13 Thread Hans du Plooy
Hi guys, I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / But it does nothing. Why? How do I do this? Thanks Hans -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of

Re: escape characters in sed

2007-05-13 Thread Jose Luis Rivas Contreras
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hans du Plooy escribió: Hi guys, I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / But it does nothing. Why? How do I do this? Well,

Re: escape characters in sed

2007-05-13 Thread Hans du Plooy
Jose Luis Rivas Contreras wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hans du Plooy escribió: Hi guys, I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / But it does nothing.

Re: escape characters in sed

2007-05-13 Thread Mathias Brodala
Hi Hans. Hans du Plooy, 13.05.2007 16:51: I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / No, just type the parenthesis, no escaping necessary. Regards, Mathias -- debian/rules

Re: escape characters in sed

2007-05-13 Thread william pursell
Hans du Plooy wrote: I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / But it does nothing. Why? How do I do this? $ echo 1.2.3.4(1.2.3.4) | sed 's/(/ /' 1.2.3.4 1.2.3.4) $ echo

Re: escape characters in sed

2007-05-13 Thread william pursell
Hans du Plooy wrote: Typo, sorry. Should be: sed 's/\\(/ /' Still doesn't work though :-) I guess the question should be, how to excape a ( character? With a backslash! The thing is, if you include the single quotes, you don't need to escape it through the shell, but if you drop the

Re: escape characters in sed

2007-05-13 Thread Hans du Plooy
Mathias Brodala wrote: Hi Hans. Hans du Plooy, 13.05.2007 16:51: I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / No, just type the parenthesis, no escaping necessary. Thanks

Re: escape characters in sed

2007-05-13 Thread Hans du Plooy
william pursell wrote: Your version is missing the final ', so I'm guessing you meant: sed 's/\\)/ /' Yes, sorry, several mistakes on my part... which will replace occurences of \) with a single space Not what I had intended, I just wanted to replace ) with a space. Actually I wanted to

Re: escape characters in sed

2007-05-13 Thread Dennis G. Wicks
Hans du Plooy wrote: Jose Luis Rivas Contreras wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hans du Plooy escribió: Hi guys, I'm trying to do a search/replace on some text. Looks like this: 1.2.3.4(1.2.3.4) To my mind, this should replace the '(' with a space sed 's/\\)/ / But