commit e7b6cc4197475229ec8ea12ac1156677eb27061d Author: Jacob Date: Tue Aug 26 21:33:27 2025 -0400 Initial commit. diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c2851a0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +*.wasm +/target +/grammars diff --git a/extension.toml b/extension.toml new file mode 100644 index 0000000..da61ac8 --- /dev/null +++ b/extension.toml @@ -0,0 +1,11 @@ +id = "scl" +name = "SCL" +description = "SCL support." +version = "0.1.0" +schema_version = 1 +authors = ["Jacob Signorovitch "] +repository = "https://git.signorovitch.org/jacob/zed-scl" + +[grammars.scl] +repository = "https://git.signorovitch.org/jacob/tree-sitter-scl" +rev = "7cad33405ec41b89a060a6bae7fb437bde99b9ed" diff --git a/languages/scl/brackets.scm b/languages/scl/brackets.scm new file mode 100644 index 0000000..d086b2e --- /dev/null +++ b/languages/scl/brackets.scm @@ -0,0 +1 @@ +("(" @open ")" @close) diff --git a/languages/scl/config.toml b/languages/scl/config.toml new file mode 100644 index 0000000..ceea231 --- /dev/null +++ b/languages/scl/config.toml @@ -0,0 +1,5 @@ +name = "SCL" +grammar = "scl" +path_suffixes = ["scl"] +line_comments = ["# "] +brackets = [{ start = "(", end = ")", close = true, newline = true }] diff --git a/languages/scl/highlights.scm b/languages/scl/highlights.scm new file mode 100644 index 0000000..137821d --- /dev/null +++ b/languages/scl/highlights.scm @@ -0,0 +1,34 @@ +;; Numbers. +(num) @number + +;; Function names when defining. +(funcdef name: (word) @function) + +;; Function calls. +(callexp fn: (word) @function) + +;; Variables. +(word) @variable + +;; Parameters inside function/lambda. +(params (word) @variable) + +;; Operators. +[ + "+" + "-" + "*" + "/" + "=" +] @operator + +;; Lambdas. +"\\" @keyword + +;; Other keywords. + +;; Parentheses. +[ "(" ")" ] @punctuation.bracket + +;; Commas. +"," @punctuation.delimiter