summary refs log tree commit diff
path: root/manifest.scm
diff options
context:
space:
mode:
Diffstat (limited to 'manifest.scm')
-rw-r--r--manifest.scm20
1 files changed, 20 insertions, 0 deletions
diff --git a/manifest.scm b/manifest.scm
new file mode 100644
index 0000000..e39196e
--- /dev/null
+++ b/manifest.scm
@@ -0,0 +1,20 @@
+;;; Guix shell manifest
+;;; SPDX-FileCopyrightText: 2025 Nguyễn Gia Phong
+;;; SPDX-License-Identifier: GPL-3.0-or-later
+
+
+(use-modules (ice-9 textual-ports))
+
+(define (read-file path)
+  (call-with-input-file path
+    (lambda (port) (get-string-all port))))
+
+(define (read-lines path)
+  (filter (compose not string-null?)
+          (string-split (read-file path)
+                        #\newline)))
+
+(let ((tree-sitter-grammars (map (lambda (language)
+                                   (string-append "tree-sitter-" language))
+                                 (read-lines "src/supported-languages"))))
+  (specifications->manifest (cons "zig" tree-sitter-grammars)))