[clue-tech] regexp question
    Kiawud 
    kiawud at gmail.com
       
    Thu Feb 10 11:48:22 MST 2005
    
    
  
On Thu, 10 Feb 2005 11:30:21 -0700, Dave Price <kinaole at gmail.com> wrote:
> Clueful Ones,
> 
> I have some files that have (what appear to be) unicode punctuation
> characters that I need to mark-up as html.
> 
> I am trying to use vim to do a search and replace for characters like
> 
> ?~@~Y  - which I want to substitute to something like  '
> 
> When I try   " :%s/?~@~Y/'/g "
> 
> In vim, I get an error:
> 
> E33: No previous substitute regular expression
> E476: Invalid command
> 
> Any ideas as to what I need to escape in these substitutions to avoid the error?
I'm not a vim expert, but you may want to try and add backspaces to
any 'special' characters.  For instance, try something like:
':%s/\?~@~Y/\'/g'
(backout other characters as well if necessary).
HTH,
-Hani
    
    
More information about the clue-tech
mailing list