0

I use the :oldfiles command a lot, but it's annoying that it gets populated with things like terminal or help buffers. My understanding is that any buffer for which a mark exist will be listed by the command, so if I close Neovim while the focus is on a help or terminal buffer, I will see those next time on the lists.

I know I can use the r option of the ShaDa file to filter out some paths by a prefix, but I wonder if there's a wider solution, after all I just care about files whose buftype is empty

1 Answer 1

1

In the end I wrote a function that wipes out all buffers whose type is help, which is executed by the VimLeavePre event, i.e. right before the ShaDa file is written

3
  • 2
    Please also include the relevant code in the post so it remains self-contained
    – D. Ben Knoble
    Jul 28, 2021 at 11:30
  • Hi Tae, it seems that you have made some change in your repository and the function is not where it was before. Could you update the link? May 5, 2022 at 15:01
  • Continuation of what Vivian said: always provide permalink instead of link relative to a movie HEAD. That will ensure the link never gets out of sync (as long as GH is online).
    – 3N4N
    Aug 22, 2022 at 8:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.