[Cialug] vi substituting

Todd Walton tdwalton at gmail.com
Sat Jan 26 09:40:03 CST 2008


I'm trying to de-dupe old mbox files.  So, I found this nifty de-duper
program at this page:
         http://www.wdr1.com/hacks/

I ran it and it seems to work fine, but every time I began a line with
"From" in my emails it thinks there's a new email, doesn't find a
Message-ID and craps out.  Luckily, it lists out those messages.  My
solution was to edit the original file, locating those "From"s and
appending "thisthis" to the beginning of the line.  I rerun the
deduper and all is well.  Now I need to go back in and remove those
^thisthis's using vim.

I open the file and say ":s/thisthis From/From/g".  vim tells me
"E486: Pattern not found: thisthis From".  Horse baloney!  If I just
straight search for it with "/thisthis From" then it finds it.  I can
see it right in front of my face.

Why doesn't vim see it when substituting?

-todd


More information about the Cialug mailing list