Re: vim - sed search/replace compatibility



Chris,

Thanks very much. I ended up just replacing any possible special
character with '.' I don't know why I didn't do that before. As Homer
Simpson says, "stupid brain!".

Again, thanks!

Mark

On Oct 23, 2:46 pm, Chris Cox <ccox_nopenott...@xxxxxxxxxxx> wrote:
shadst...@xxxxxxxxx wrote:
oops. I meant an 'ed' script. sorry.

On Oct 21, 1:02 pm, shadst...@xxxxxxxxx wrote:
Hi,

I'm using this:

:%s/file:\/\/\/C:\\Documents%20and%20Settings\\Tom\\Desktop\\Web%20Pics\\/\/pics\//

to do a search/replace in vim. But using:

ed $1 <<END
1,$
s/file:\/\/\/C:\\Documents\%20and\%20Settings\\Tom\\Desktop\\Web\%20Pics\\/\/pics\//
w
q
END

in a sed script doesn't work. I would be grateful if someone could show
where I'm going wrong.

Thank you in advance.

Mark ShadleyEscape the backslashes using a character class.
[\]
See if that helps.

.



Relevant Pages

  • Re: Maytag dishwater control board... thermistor part number ?
    ... Homer J Simpson wrote: ... So that's why they won't argue with you? ...
    (sci.electronics.repair)
  • Re: Can base amperage on an NPN be negative, and still work?
    ... Homer J Simpson wrote: ... "No one has proven that aliens do not exist. ... Therefore, based on that alone, they must exist, notwithstanding that I have ... You can't even prove that you exist because all references to "Homer ...
    (sci.electronics.design)
  • Re: Replace Formatting Styles in 3000 docs
    ... replacing text and it worked great, replacing text within 20 files in ... SrchAndRplInStry = False ... "Invalid Special Character." ... Word MVP web sitehttp://word.mvps.org ...
    (microsoft.public.word.vba.general)
  • Re: HDMI cables a "Ripoff"
    ... GPL Handicap 6.35 ... "Homer no function beer well without." ... - H.J. Simpson ...
    (alt.tv.tech.hdtv)
  • Re: So as an emphatic
    ... They lost one of the original sextet, but rather than replacing him with an utterly different character, they replaced him with someone who is virtually a clone -- his lines, his quirks, even his appearance, his entire persona could just as well have been embodied in the original character. ... possibly as many as four episodes, and even though the scripts were identical but for the slang, they didn't work at all. ... but they aren't using the same scripts, and of course because they have to interrupt for commercials, the long, awkward pauses aren't quite long and awkward enough.) ...
    (sci.lang)

Loading