mirror of
https://github.com/neovim/neovim.git
synced 2025-12-16 19:35:37 +00:00
feat(runtime): add query filetype (#17905)
used for Tree-sitter queries uses Lisp runtime files (in Lua to distinguish from upstream runtime files)
This commit is contained in:
6
runtime/ftplugin/query.lua
Normal file
6
runtime/ftplugin/query.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- Neovim filetype plugin file
|
||||||
|
-- Language: Tree-sitter query
|
||||||
|
-- Last Change: 2022 Mar 29
|
||||||
|
|
||||||
|
-- it's a lisp!
|
||||||
|
vim.cmd [[ runtime! ftplugin/lisp.vim ]]
|
||||||
6
runtime/indent/query.lua
Normal file
6
runtime/indent/query.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
-- Neovim indent file
|
||||||
|
-- Language: Tree-sitter query
|
||||||
|
-- Last Change: 2022 Mar 29
|
||||||
|
|
||||||
|
-- it's a lisp!
|
||||||
|
vim.cmd [[ runtime! indent/lisp.vim ]]
|
||||||
@@ -1424,6 +1424,8 @@ local pattern = {
|
|||||||
return "git"
|
return "git"
|
||||||
end
|
end
|
||||||
end,
|
end,
|
||||||
|
-- Neovim only
|
||||||
|
[".*/queries/.*%.scm"] = "query", -- tree-sitter queries
|
||||||
-- END PATTERN
|
-- END PATTERN
|
||||||
}
|
}
|
||||||
-- luacheck: pop
|
-- luacheck: pop
|
||||||
|
|||||||
Reference in New Issue
Block a user