Is it possible to show/hide all matching lines in vi or Vim? Not highlight but just show only those lines.
For example I have a text with word the word ERROR
ERROR
Do you know about the :global command? Does this do what you want?
:global
:g/ERROR
and for the opposite:
:g!/Error
or equivalently:
:v/Error