From f2ed26857a2b749545be67c5bab3c3037eabb3f5 Mon Sep 17 00:00:00 2001 From: jaredmontoya <49511278+jaredmontoya@users.noreply.github.com> Date: Sat, 28 Jun 2025 22:01:44 +0200 Subject: [PATCH] tree-sitter-grammars.tree-sitter-qmljs: init --- .../tools/parsing/tree-sitter/grammars/default.nix | 2 +- .../tree-sitter/grammars/grammar-sources.nix | 14 ++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/pkgs/development/tools/parsing/tree-sitter/grammars/default.nix b/pkgs/development/tools/parsing/tree-sitter/grammars/default.nix index c61bb8046e91a..82437c2b95041 100644 --- a/pkgs/development/tools/parsing/tree-sitter/grammars/default.nix +++ b/pkgs/development/tools/parsing/tree-sitter/grammars/default.nix @@ -10,7 +10,7 @@ let /** Set of grammar sources. See ./grammar-sources.nix to define a new grammar. */ - grammar-sources = import ./grammar-sources.nix; + grammar-sources = import ./grammar-sources.nix { inherit lib; }; /** Parse a flakeref style string to { type, owner, repo, ref } diff --git a/pkgs/development/tools/parsing/tree-sitter/grammars/grammar-sources.nix b/pkgs/development/tools/parsing/tree-sitter/grammars/grammar-sources.nix index 2fa19af65f72b..42a7e269cbd90 100644 --- a/pkgs/development/tools/parsing/tree-sitter/grammars/grammar-sources.nix +++ b/pkgs/development/tools/parsing/tree-sitter/grammars/grammar-sources.nix @@ -1,3 +1,5 @@ +{ lib }: + { bash = { version = "0.23.3"; @@ -527,6 +529,18 @@ hash = "sha256-mJ/bj09mT1WTaiKoXiRXDM7dkenf5hv2ArXieeTVe6I="; }; + qmljs = rec { + version = "0.3.0"; + url = "github:yuja/tree-sitter-qmljs?ref=${version}"; + hash = "sha256-tV4lipey+OAQwygRFp9lQAzgCNiZzSu7p3Mr6CCBH1g="; + meta = { + license = lib.licenses.mit; + maintainers = with lib.maintainers; [ + jaredmontoya + ]; + }; + }; + query = { version = "0.5.0"; url = "github:nvim-treesitter/tree-sitter-query";