SUMMARY: Searchstring with tilde in vi

From: hans van der heide <hans.vanderheide_at_bdl.ch>
Date: Wed, 25 Sep 2002 16:18:35 +0200

Hi folks,

According to the many answers I already received, escaping the tilde with a
backslash should work.
I tried it on another Tru64 System and - look-and-wonder - I could search
and find all tildes.
Probably the system I tested on, wasn't setup correctly (I also had many
problems with tabs settings a.s.o.)


[\~] works for me. (Just [~] works in vim.)
:/\~/ worked for me

Thanks for your quick responses in just 5 minutes

Paul A Sand,
Peter Sherwood (yes I thought it was a Tru64 problem, cause it seemed to
occur only on Tru64, not linux, not ultrix)
Gert Maaskant (ja ik ben hollander, maar woon in zwitserl)

and probably many others to come telling me it should work

Greetings,

Hans van der Heide ( mailto:hans.vanderheide_at_bdl.ch )

Original Question:
Hello folks,

I am struggling with the following:

How can I search with "vi" for the character "~" (tilde). I do not know of a
way escaping this character (implemented in vi as a shortcut for saved last
searchresult): the backslash doesn't work for tilde, i cannot use a [.-.] or
[^.-.] sequence as a trick because tilde is the last printable below 0x7F.

Anybody know a trick?


Greetings,

Hans van der Heide ( mailto:hans.vanderheide_at_bdl.ch )
Received on Wed Sep 25 2002 - 14:19:33 NZST

This archive was generated by hypermail 2.4.0 : Wed Nov 08 2023 - 11:53:43 NZDT