From 64b3d5e5698d485a4f197ffbe85a4b6c29e16325 Mon Sep 17 00:00:00 2001 From: tk-shirasaka Date: Sat, 20 Jan 2024 21:34:49 +0900 Subject: feat: add the php_only parser included in tree-sitter-php (#5876) Add parser `php_only` for PHP files without HTML embedded. Make queries for combined parser `php` inherit from `php_only` (no extensions needed). --------- Co-authored-by: shirasaka --- lua/nvim-treesitter/parsers.lua | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'lua') diff --git a/lua/nvim-treesitter/parsers.lua b/lua/nvim-treesitter/parsers.lua index d60553206..7a945e11e 100644 --- a/lua/nvim-treesitter/parsers.lua +++ b/lua/nvim-treesitter/parsers.lua @@ -1332,6 +1332,15 @@ list.php = { maintainers = { "@tk-shirasaka" }, } +list.php_only = { + install_info = { + url = "https://github.com/tree-sitter/tree-sitter-php", + location = "php_only", + files = { "src/parser.c", "src/scanner.c" }, + }, + maintainers = { "@tk-shirasaka" }, +} + -- Parsers for injections list.phpdoc = { install_info = { -- cgit v1.2.3-70-g09d2