-
-
Notifications
You must be signed in to change notification settings - Fork 189
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buffer grouping #56
Comments
@CooperAnderson potentially the filtering you had in your PR could be done on top of this e.g. certain groups could be assigned to specific tabs etc., thoughts? |
Is there any updates on buffer groups? |
Nope. Haven't looked into it properly. A big part of the way centaur-tabs does it is that it can render the UI in a way that can't really be achieved in nvim so not super clear how this would look. It's also a non-trivial amount of work I don't currently have time for. |
Idk if this sounds dumb lol , maybe you can use one buffer for grouping multiple buffers and pressing a mapping when you're in the group buffer will open a lil popup over the bottom of the grouped buffer and cycling within the popup ( of grouped buffer ) with a mapping. |
@siduck76 I've already started some work over in #179 I'm probably not going to go with the structure above since that is way more work/complexity i.e. hiding buffers and then trying to add a new secondary UI. The main way this is probably going to work will be different highlighting/icons for grouped buffers and just as a visual indicator, I might also allow some custom separator e.g. a space or divider between groups or a sort of header tab. Anyway I'm trying to keep the initial implementation lean so won't be adding a bunch of complexity otherwise chances are I'll never finish anyway. You can have a look at that PR to see where it's at. It's not fully documented yet though |
I'm sure I understand tbh or if it relates to this particular functionality at all really. |
Hi @akinsho & @siduck76, I thought I might explain my implementation a little, though mine clearly has flaws with it's implementation as it is currently. (I intend to improve it after my exams soon!) On Terminal creation,
This code is an edited excerpt from here Closing buffersThere are several implementation choices to make:
We implemented # 2
What
|
@G-Rowell thanks for explaining the terminal functionality referenced above. Just to clarify, I think there's generally a bit of confusion about what this issue is about and what the related PR will do. It doesn't have anything to do with hiding buffers or toggling things or secondary UI's. The buffer group logic is a mechanism for users to specify how buffers get grouped, things like highlights and icons for a group and exposes functionality for interacting with a group e.g. all test files are grouped or all files matching some other criteria can be grouped and then closed together, or opened in splits all at once. I don't think most of the recent comments really relate to this issue, just to be clear. |
Yeah, my apologies, I barely got any sleep last night 😢 I was mainly trying to supplement SiDuck's answer. I'm slightly more awake now and agree, it's quite irrelevant. Let me know if you want me to ping you if I do get bufferline grouping working |
closed by #179 |
One thing I've thought a lot about since I discovered emacs' Centaur tabs is it's buffer groups I was initially against the idea since it seemed like an extra layer on top of vim that doesn't really exist natively. But with sorting added we already essentially have this layer on top of nvim 🤔 .
Anyway a first pass at this functionality would be added a way of first creating a group, then assigning buffers to a group. Visually groups would be clustered together +/- a way to separate them from each other or indicate that a buffer was in a particular group
The primary value of the groups would be visually seeing similar things clustered e.g. test files or some other dimension for sorting that isn't just an extension or directory. It would also have the benefit of allowing a user to interact with those buffers as a group
The text was updated successfully, but these errors were encountered: