plugins/syntax: fix tree-sitter parsers
This commit is contained in:
parent
d576379760
commit
69355e6429
1 changed files with 5 additions and 4 deletions
|
@ -21,14 +21,15 @@ let
|
|||
};
|
||||
|
||||
tree-sitter = (inputs.tree-sitter.override { inherit extraGrammars; });
|
||||
grammars = tree-sitter.withPlugins (g: tree-sitter.allGrammars);
|
||||
grammars = tree-sitter.withPlugins (g: [ g.tree-sitter-d2 ]);
|
||||
|
||||
nvim-treesitter = inputs.nvim-treesitter.overrideAttrs (oldAttrs: {
|
||||
nvim-treesitter = inputs.nvim-treesitter.withAllGrammars.overrideAttrs (oldAttrs: {
|
||||
postPatch = ''
|
||||
rm -r parser
|
||||
ln -s ${grammars} parser
|
||||
mkdir parser
|
||||
ln -s ${grammars}/d2.so parser/d2.so
|
||||
|
||||
ln -s ${../.}/queries queries/d2
|
||||
ln -s ${extraGrammars.tree-sitter-d2.src}/queries queries/d2
|
||||
'';
|
||||
});
|
||||
in
|
||||
|
|
Reference in a new issue