-
Notifications
You must be signed in to change notification settings - Fork 1
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
Continue item numbering on enter #6
Comments
lists.vim uses
if you now go to the end of the third line, then press enter, then |
Its not working. Its giving some random results. In a file named hera.wiki:
|
That's strange. On my side, that works exactly as expected... Let's simplify everything here:
Also, what's the output of doing |
Its working. |
Ok. Now, with that, you could possibly map imap <cr> <cr><plug>(lists-new-element) However, this won't work quite as desired. You need something more advanced, because you don't want to add the new element except if the text just above is a list. There are likely many more edge cases that should be handled. And the map should only be applied when you enable lists.vim. Also, other plugins might suggest/want to remap This is precisely why I did not create this functionality. To me, it seems simpler and more robust to instead add a separate map for the action of "create new element/item/bullet". |
I do agree with the point of conflict with other plugin. And I do not mind one more keystroke for next line number. What if you provided option to enable/disable completion ? Let the user be responsible what happens next. |
Could you explain a bit more? I don't quite get what you mean, sorry. |
I meant something like |
Sorry, but that's not very verbose. Can you explain how the option would work? Preferably with an example or two? |
I meant just set it in your vimrc and enable/disable auto completion if provided. |
What do you mean with auto completion? I think I'm confused, because I wrote earlier:
To which you responded
It seems you first agree that I should not add the feature, then you start talking about completion. Completion is in itself a specific concept in Vim/neovim, and what we are discussing is not completion (see If so, I'm still not sure I want that, because, as I tried to explain, it is quite complicated and can easily go wrong. |
I agreed that the feature can cause issues. And I know the about keyword auto completion. Your resistance to the feature may be right but I am right about its usefulness as well. |
I spend quite a lot of time writing and maintaining Vim plugins, and my time is unfortunately severely limited. "Resisting" feature requests is unfortunately important to avoid being overwhelmed. It does not mean that your request is bad or that you are wrong. It simply means that I am considering if this is what I want to spend my time doing. Notice that my questions in this thread were not meant as resistance. Instead, I was genuinely trying to understand what you wanted/suggested so that I could be able to decide if it was something I was willing to implement from my side. |
I appreciate your time and effort the same way I understand about the feature request. |
Hey. First, thanks for this minimal plugin. I'd also like to express my preference this behaviour — specifically for unordered lists. While Let me know what you think of this. I think, just setting what Vim considers as comments should be enough to achieve this right? I remember using this to continue/auto-add comments in the past. |
I'm glad you like it!
I mostly work with unordered lists. ;)
I'm an avid user of tmux. I use
Yes, combined with Lines 9 to 10 in 33ced55
The main thing to change here is to remove the I personally prefer it to be the way it is. Also, if I were to add an option to not include the |
I too would like lists to automatically continue when I press Enter. However, lervag's reluctance is justified. bullets.vim does continue lists on Enter, but there are several bugs with the implementation, to the point that I have switched to lists.vim instead. It's easier to press I remain hopeful that someone will one day create a plugin which automatically continues lists without introducing conflicts and bugs. But until then, I'm happy to press |
After pressing enter, next item in list should get the item number automatically.
The text was updated successfully, but these errors were encountered: