add queries for different tree-sitter-based editors
i think queries should be written for tree-sitter-based editors to enable syntax highlighting
resources:
- official tree-sitter query docs
- neovim - nvim-treesitter docs
- helix - helix query docs
- lapce - lapce docs
on neovim i followed the instructions from @zioroboco but i still had to run
mkdir ~/.local/share/nvim/lazy/nvim-treesitter/queries/nu/
http get https://raw.githubusercontent.com/1Kinoti/_tree-sitter-nu/main/queries/helix/highlights.scm | save ~/.local/share/nvim/lazy/nvim-treesitter/queries/nu/highlights.scm
to install the queries from your fork @1Kinoti to neovim :open_mouth:
it would be very cool to have that automated :yum:
@amtoine I believe the queries need to be in this tree-sitter-nu repo once we've developed them. We can start with @1Kinoti's if we want to but if you look at the helix queries from LhKipp's tree-sitter, you'll notice there are more than just one query file. I think this is all part of creating the tree-sitter part and it's just not finished yet. We added this repository in the hopes that people would jump in and add what's missing. Maybe I'm preaching to the choir here. Sorry if I am.
oooh yeah you are absolutely right here :yum:
can we start now with the highlights.csm file above? it adds a lot to the experience i think
@amtoine We can I think. @1Kinoti is it ok to add that file? Since it existed in your repo after the merge, I just want to ask to be sure it's ok.
the file is not tested, that is why i did not include it. i was just using it to learn how to write queries. but if @amtoine tests it then it can be added
Lapce appears to use queries that look very similar to nvim/helix queries. Does anyone use Lapce and has tried them?