zed-industries / zed

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
https://zed.dev
Other
46.98k stars 2.7k forks source link

Vim treesitter syntax motions should take a count #17245

Open baffalop opened 2 weeks ago

baffalop commented 2 weeks ago

Check for existing issues

Describe the feature

I'm just starting to explore Zed and I'm quite excited! I just found out about the special treesitter syntax tree motions ]x and ]x, which are really cool! But one of the first things I tried with that is to give a count, eg. 3[x or [3x. In the first, the count was ignored, and in the second, the [ was ignored.

I would probably go with [3x, on analogy with things like c3aB: I would expect this to select the 3rd node up in the tree, ie. the equivalent of repeating [x 3 times. Perhaps 3[x should be treated the same way.

If applicable, add mockups / screenshots to help present your vision of the feature

No response

ConradIrwin commented 1 week ago

:+1: If you'd like to pair with me on this: https://calendly.com/conradirwin/pairing