taji01 taji01 - 2 years ago 114
Linux Question

Search VI for letters and numbers

I use vi at work and i have to search for a string of specific letters & numbers such as these:


there are always (3)Letters and (5)Numbers. Is there a way to search for these strings easily? Maybe with regex or something else.

Answer Source

Just type


The \v activates the very magic mode to avoid escaping here. What follows is probably self-explanatory, assuming you know that \d is a digit in regular expressions.

Documentation on searching in vim

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download