Re: Collapse out all lines not matching "/pattern"?

Igbanam Ogbuluijah <[email protected]> Sun, 13 Jul 2025 22:00:18 +0000
Newsgroups gmane.editors.vim
Message-ID <CAOmRJrfgQz-M445OuhF1M7Jejr2iVeCyihQbawZU+tmxgHsHTQ@mail.gmail.com>
My go-to for folding is vim-anyfold
<https://github.com/pseewald/vim-anyfold>. It just works™


*Igbanam*


On Sun, Jul 13, 2025 at 8:37 PM Gary Johnson <[email protected]> wrote:

> On 2025-07-13, Joseph Wulf wrote:
> > In regular/normal vim editing, is there a method to collapse out of view
> all
> > lines NOT matching "/pattern"?
> >
> > Though I use vimdiff a lot, the only relevance to vimdiff is the way it
> > collapses out lines not relevant to the differentiation process.  So,
> when I'm
> > using regular VIM, I'm wondering if there's a way to search for
> "/pattern"
> > ---and--- only see matching lines?  I also tend to have line numbers on
> a lot,
> > which would greatly help me to focus on certain things.
>
> I use the searchfold.vim plugin for this.  It's available at these
> places:
>
>     https://github.com/vim-scripts/searchfold.vim
>     https://www.vim.org/scripts/script.php?script_id=2521
>
> It's 14 years old now, but it continues to "just work".
>
> Regards,
> Gary
>
> --
> --
> You received this message from the "vim_use" maillist.
> Do not top-post! Type your reply below the text you are replying to.
> For more information, visit http://www.vim.org/maillist.php
>
> ---
> You received this message because you are subscribed to the Google Groups
> "vim_use" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion visit
> https://groups.google.com/d/msgid/vim_use/20250713203923.GF24703%40phoenix
> .
>

-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/d/msgid/vim_use/CAOmRJrfgQz-M445OuhF1M7Jejr2iVeCyihQbawZU%2BtmxgHsHTQ%40mail.gmail.com.