-
Notifications
You must be signed in to change notification settings - Fork 182
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
Move object supports visual and operator-pending modes #329
Conversation
Thank you! |
Head branch was pushed to by a user without write access
Thanks for the approval. I noticed my change affected swap and lsp_interop keybindings as well, so I made another commit to fix it. Now, |
ea6e12e
to
7f70e79
Compare
7f70e79
to
1fe3755
Compare
1fe3755
to
6b89ae9
Compare
@kiyoon you seem to be very active in improving this plugin. Would you be interested in helping with maintaining this repository? |
Thanks for the offer! I by no means have a full understanding of the project, but I'm happy to help and looking forward to further contributions :) |
At the moment, I only have little time to look at open PRs and I don't use the plugin often enough to feel confident about changes. It would be good when somebody who uses it more frequently would have a look which changes do make sense and which one These are some ideas I wanted to implement for a
I think I will be opening a issues with a "call for maintainers". So we can together tackle the open tasks. |
The milestones sound good.
I'll check the call-for-maintainers issues whenever I have time. |
I have an idea for the tests. We can pull many code from many open sourcr projects. We divide that into two categories: stable version from popular projects, and unstable any repositories. We run many sets of treesitter select, swap, move operations. Manipulate the code with the selection (like replace the selection to something) and keep the diff of the files. Maybe we shouldn't keep this data in the git repo though. For every commit, we perform the "consistency test", to ensure the manipulation behaviour is equal to the previous commit. If the test fails, we can investigate what changed. If we made a breaking change (like we fixed bug in movement) then we can just enforce the commit with updating the tests. The second split of the data (random code, not popular repos) can introuce a lot of edge cases due to the code not structured or complete. How does this sound? Since I don't work with every language, it's hard to write all tests so this way it should be a good starting point of the automated tests. |
This pull request resolves #6, to make the move operation consistent with vim's behaviour.
Now you can move in visual mode or operator-pending mode.
For example,
v]M
will select until the end of the function, assuming the key binding following the README.dv]M
will delete until the end of the function.