diff options
author | Liliana Marie Prikler <liliana.prikler@gmail.com> | 2023-09-09 12:22:14 +0200 |
---|---|---|
committer | Liliana Marie Prikler <liliana.prikler@gmail.com> | 2023-09-09 12:22:14 +0200 |
commit | 94ca5b4357af8f8921f0cb0873a7cf316f13aa69 (patch) | |
tree | 6ef30120737f26f298f7f17d86597b0b729517e0 /gnu/packages/tree-sitter.scm | |
parent | 6750c114e3e988249f4069d0180316c6d0192350 (diff) | |
parent | db61bdd7f52270a35bd0a3a88650d98276dab20b (diff) | |
download | guix-94ca5b4357af8f8921f0cb0873a7cf316f13aa69.tar.gz guix-94ca5b4357af8f8921f0cb0873a7cf316f13aa69.zip |
Merge branch 'master' into emacs-team
Diffstat (limited to 'gnu/packages/tree-sitter.scm')
-rw-r--r-- | gnu/packages/tree-sitter.scm | 31 |
1 files changed, 29 insertions, 2 deletions
diff --git a/gnu/packages/tree-sitter.scm b/gnu/packages/tree-sitter.scm index 4b191d4978..58db2603af 100644 --- a/gnu/packages/tree-sitter.scm +++ b/gnu/packages/tree-sitter.scm @@ -271,11 +271,14 @@ This package includes the @command{tree-sitter} command-line tool.") (grammar-directories '(".")) (article "a") (inputs '()) + (get-cleanup-snippet tree-sitter-delete-generated-files) (license license:expat)) "Returns a package for Tree-sitter grammar. NAME will be used with tree-sitter- prefix to generate package name and also for generating REPOSITORY-URL value if it's not specified explicitly, TEXT is a string which -will be used in description and synopsis." +will be used in description and synopsis. GET-CLEANUP-SNIPPET is a function, +it recieves GRAMMAR-DIRECTORIES as an argument and should return a G-exp, +which will be used as a snippet in origin." (let* ((multiple? (> (length grammar-directories) 1)) (grammar-names (string-append text " grammar" (if multiple? "s" ""))) (synopsis (string-append "Tree-sitter " grammar-names)) @@ -296,7 +299,7 @@ will be used in description and synopsis." (file-name (git-file-name name version)) (sha256 (base32 hash)) (snippet - (tree-sitter-delete-generated-files grammar-directories)))) + (get-cleanup-snippet grammar-directories)))) (build-system tree-sitter-build-system) (arguments (list #:grammar-directories grammar-directories)) (inputs inputs) @@ -359,6 +362,13 @@ will be used in description and synopsis." #:commit commit #:inputs (list tree-sitter-c)))) +(define-public tree-sitter-cmake + (tree-sitter-grammar + "cmake" "CMake" + "1z49jdachwxwbzrrapskpi2kxq3ydihfj45ab9892gbamfij2zp5" + "0.4.1" + #:repository-url "https://github.com/uyha/tree-sitter-cmake")) + (define-public tree-sitter-elixir ;; No tags at all, version in the source code is 0.19.0 (let ((commit "b20eaa75565243c50be5e35e253d8beb58f45d56") @@ -580,3 +590,20 @@ will be used in description and synopsis." (git-version "0.1.0" revision commit) #:repository-url "https://github.com/6cdh/tree-sitter-racket" #:commit commit))) + +(define-public tree-sitter-plantuml + ;; No tags + (let ((commit "bea443ef909484938cb0a9176ebda7b8a3d108f7") + (revision "0")) + (tree-sitter-grammar + "plantuml" "PlantUML" + "0swqq4blhlvvgrvsb0h4cjl3pnfmmdpfd5r5kg9rpdwk0sn98x3a" + (git-version "1.0.0" revision commit) + #:repository-url "https://github.com/Decodetalkers/tree_sitter_plantuml" + #:commit commit + #:get-cleanup-snippet + (lambda _ + #~(begin + (use-modules (guix build utils)) + (delete-file "binding.gyp") + (delete-file-recursively "bindings")))))) |