mirror of
https://github.com/zed-industries/zed.git
synced 2024-09-18 18:08:07 +03:00
bump tree-sitter-nu to latest (#8059)
This PR bumps the tree-sitter-nu commit to the latest supported by the nushell team. It also includes the latest highlights.scm Release Notes: Bumped `nu` tree sitter dependency and highlights.scm
This commit is contained in:
parent
0a40a21c74
commit
91b97387b6
@ -256,7 +256,7 @@ tree-sitter-json = { git = "https://github.com/tree-sitter/tree-sitter-json", re
|
|||||||
tree-sitter-lua = "0.0.14"
|
tree-sitter-lua = "0.0.14"
|
||||||
tree-sitter-markdown = { git = "https://github.com/MDeiml/tree-sitter-markdown", rev = "330ecab87a3e3a7211ac69bbadc19eabecdb1cca" }
|
tree-sitter-markdown = { git = "https://github.com/MDeiml/tree-sitter-markdown", rev = "330ecab87a3e3a7211ac69bbadc19eabecdb1cca" }
|
||||||
tree-sitter-nix = { git = "https://github.com/nix-community/tree-sitter-nix", rev = "66e3e9ce9180ae08fc57372061006ef83f0abde7" }
|
tree-sitter-nix = { git = "https://github.com/nix-community/tree-sitter-nix", rev = "66e3e9ce9180ae08fc57372061006ef83f0abde7" }
|
||||||
tree-sitter-nu = { git = "https://github.com/nushell/tree-sitter-nu", rev = "26bbaecda0039df4067861ab38ea8ea169f7f5aa" }
|
tree-sitter-nu = { git = "https://github.com/nushell/tree-sitter-nu", rev = "7dd29f9616822e5fc259f5b4ae6c4ded9a71a132" }
|
||||||
tree-sitter-ocaml = { git = "https://github.com/tree-sitter/tree-sitter-ocaml", rev = "4abfdc1c7af2c6c77a370aee974627be1c285b3b" }
|
tree-sitter-ocaml = { git = "https://github.com/tree-sitter/tree-sitter-ocaml", rev = "4abfdc1c7af2c6c77a370aee974627be1c285b3b" }
|
||||||
tree-sitter-php = "0.21.1"
|
tree-sitter-php = "0.21.1"
|
||||||
tree-sitter-prisma-io = { git = "https://github.com/victorhqc/tree-sitter-prisma" }
|
tree-sitter-prisma-io = { git = "https://github.com/victorhqc/tree-sitter-prisma" }
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
;;; keywords
|
;;; keywords
|
||||||
[
|
[
|
||||||
"def"
|
"def"
|
||||||
"def-env"
|
|
||||||
"alias"
|
"alias"
|
||||||
"export-env"
|
"export-env"
|
||||||
"export"
|
"export"
|
||||||
@ -46,22 +45,22 @@
|
|||||||
"for" @keyword
|
"for" @keyword
|
||||||
"in" @keyword
|
"in" @keyword
|
||||||
)
|
)
|
||||||
(overlay_list "list" @keyword)
|
(overlay_list "list" @keyword.storage.modifier)
|
||||||
(overlay_hide "hide" @keyword)
|
(overlay_hide "hide" @keyword.storage.modifier)
|
||||||
(overlay_new "new" @keyword)
|
(overlay_new "new" @keyword.storage.modifier)
|
||||||
(overlay_use
|
(overlay_use
|
||||||
"use" @keyword
|
"use" @keyword.storage.modifier
|
||||||
"as" @keyword
|
"as" @keyword
|
||||||
)
|
)
|
||||||
(ctrl_error "make" @keyword)
|
(ctrl_error "make" @keyword.storage.modifier)
|
||||||
|
|
||||||
;;; ---
|
;;; ---
|
||||||
;;; literals
|
;;; literals
|
||||||
(val_number) @constant
|
(val_number) @constant.numeric
|
||||||
(val_duration
|
(val_duration
|
||||||
unit: [
|
unit: [
|
||||||
"ns" "µs" "us" "ms" "sec" "min" "hr" "day" "wk"
|
"ns" "µs" "us" "ms" "sec" "min" "hr" "day" "wk"
|
||||||
] @variable
|
] @variable.parameter
|
||||||
)
|
)
|
||||||
(val_filesize
|
(val_filesize
|
||||||
unit: [
|
unit: [
|
||||||
@ -73,7 +72,6 @@
|
|||||||
"tb" "tB" "Tb" "TB"
|
"tb" "tB" "Tb" "TB"
|
||||||
"pb" "pB" "Pb" "PB"
|
"pb" "pB" "Pb" "PB"
|
||||||
"eb" "eB" "Eb" "EB"
|
"eb" "eB" "Eb" "EB"
|
||||||
"zb" "zB" "Zb" "ZB"
|
|
||||||
|
|
||||||
"kib" "kiB" "kIB" "kIb" "Kib" "KIb" "KIB"
|
"kib" "kiB" "kIB" "kIb" "Kib" "KIb" "KIB"
|
||||||
"mib" "miB" "mIB" "mIb" "Mib" "MIb" "MIB"
|
"mib" "miB" "mIB" "mIb" "Mib" "MIb" "MIB"
|
||||||
@ -81,28 +79,27 @@
|
|||||||
"tib" "tiB" "tIB" "tIb" "Tib" "TIb" "TIB"
|
"tib" "tiB" "tIB" "tIb" "Tib" "TIb" "TIB"
|
||||||
"pib" "piB" "pIB" "pIb" "Pib" "PIb" "PIB"
|
"pib" "piB" "pIB" "pIb" "Pib" "PIb" "PIB"
|
||||||
"eib" "eiB" "eIB" "eIb" "Eib" "EIb" "EIB"
|
"eib" "eiB" "eIB" "eIb" "Eib" "EIb" "EIB"
|
||||||
"zib" "ziB" "zIB" "zIb" "Zib" "ZIb" "ZIB"
|
] @variable.parameter
|
||||||
] @variable
|
|
||||||
)
|
)
|
||||||
(val_binary
|
(val_binary
|
||||||
[
|
[
|
||||||
"0b"
|
"0b"
|
||||||
"0o"
|
"0o"
|
||||||
"0x"
|
"0x"
|
||||||
] @constant
|
] @constant.numeric
|
||||||
"[" @punctuation.bracket
|
"[" @punctuation.bracket
|
||||||
digit: [
|
digit: [
|
||||||
"," @punctuation.delimiter
|
"," @punctuation.delimiter
|
||||||
(hex_digit) @constant
|
(hex_digit) @constant.number
|
||||||
]
|
]
|
||||||
"]" @punctuation.bracket
|
"]" @punctuation.bracket
|
||||||
) @constant
|
) @constant.numeric
|
||||||
(val_bool) @constant.builtin
|
(val_bool) @constant.builtin
|
||||||
(val_nothing) @constant.builtin
|
(val_nothing) @constant.builtin
|
||||||
(val_string) @string
|
(val_string) @string
|
||||||
(val_date) @constant
|
(val_date) @constant.number
|
||||||
(inter_escape_sequence) @constant
|
(inter_escape_sequence) @constant.character.escape
|
||||||
(escape_sequence) @constant
|
(escape_sequence) @constant.character.escape
|
||||||
(val_interpolated [
|
(val_interpolated [
|
||||||
"$\""
|
"$\""
|
||||||
"$\'"
|
"$\'"
|
||||||
@ -111,7 +108,7 @@
|
|||||||
] @string)
|
] @string)
|
||||||
(unescaped_interpolated_content) @string
|
(unescaped_interpolated_content) @string
|
||||||
(escaped_interpolated_content) @string
|
(escaped_interpolated_content) @string
|
||||||
(expr_interpolated ["(" ")"] @variable)
|
(expr_interpolated ["(" ")"] @variable.parameter)
|
||||||
|
|
||||||
;;; ---
|
;;; ---
|
||||||
;;; operators
|
;;; operators
|
||||||
@ -144,22 +141,7 @@
|
|||||||
"not-in"
|
"not-in"
|
||||||
"starts-with"
|
"starts-with"
|
||||||
"ends-with"
|
"ends-with"
|
||||||
] @operator)
|
] @operator )
|
||||||
|
|
||||||
(expr_binary opr: ([
|
|
||||||
"and"
|
|
||||||
"or"
|
|
||||||
"xor"
|
|
||||||
"bit-or"
|
|
||||||
"bit-xor"
|
|
||||||
"bit-and"
|
|
||||||
"bit-shl"
|
|
||||||
"bit-shr"
|
|
||||||
"in"
|
|
||||||
"not-in"
|
|
||||||
"starts-with"
|
|
||||||
"ends-with"
|
|
||||||
]) @keyword)
|
|
||||||
|
|
||||||
(where_command [
|
(where_command [
|
||||||
"+"
|
"+"
|
||||||
@ -245,18 +227,18 @@
|
|||||||
;;; ---
|
;;; ---
|
||||||
;;; identifiers
|
;;; identifiers
|
||||||
(param_rest
|
(param_rest
|
||||||
name: (_) @variable)
|
name: (_) @variable.parameter)
|
||||||
(param_opt
|
(param_opt
|
||||||
name: (_) @variable)
|
name: (_) @variable.parameter)
|
||||||
(parameter
|
(parameter
|
||||||
param_name: (_) @variable)
|
param_name: (_) @variable.parameter)
|
||||||
(param_cmd
|
(param_cmd
|
||||||
(cmd_identifier) @string)
|
(cmd_identifier) @string)
|
||||||
(param_long_flag) @variable
|
(param_long_flag) @variable.parameter
|
||||||
(param_short_flag) @variable
|
(param_short_flag) @variable.parameter
|
||||||
|
|
||||||
(short_flag) @variable
|
(short_flag) @variable.parameter
|
||||||
(long_flag) @variable
|
(long_flag) @variable.parameter
|
||||||
|
|
||||||
(scope_pattern [(wild_card) @function])
|
(scope_pattern [(wild_card) @function])
|
||||||
|
|
||||||
@ -271,29 +253,29 @@
|
|||||||
|
|
||||||
(path
|
(path
|
||||||
["." "?"] @punctuation.delimiter
|
["." "?"] @punctuation.delimiter
|
||||||
) @variable
|
) @variable.parameter
|
||||||
|
|
||||||
(val_variable
|
(val_variable
|
||||||
"$" @operator
|
"$" @variable.parameter
|
||||||
[
|
[
|
||||||
(identifier) @variable
|
(identifier) @namespace
|
||||||
"in" @type.builtin
|
"in"
|
||||||
"nu" @type.builtin
|
"nu"
|
||||||
"env" @type.builtin
|
"env"
|
||||||
"nothing" @type.builtin
|
"nothing"
|
||||||
] ; If we have a special styling, use it here
|
] @special
|
||||||
)
|
)
|
||||||
;;; ---
|
;;; ---
|
||||||
;;; types
|
;;; types
|
||||||
(flat_type) @type.builtin
|
(flat_type) @type.builtin
|
||||||
(list_type
|
(list_type
|
||||||
"list" @type
|
"list" @type.enum
|
||||||
["<" ">"] @punctuation.bracket
|
["<" ">"] @punctuation.bracket
|
||||||
)
|
)
|
||||||
(collection_type
|
(collection_type
|
||||||
["record" "table"] @type
|
["record" "table"] @type.enum
|
||||||
"<" @punctuation.bracket
|
"<" @punctuation.bracket
|
||||||
key: (_) @variable
|
key: (_) @variable.parameter
|
||||||
["," ":"] @punctuation.delimiter
|
["," ":"] @punctuation.delimiter
|
||||||
">" @punctuation.bracket
|
">" @punctuation.bracket
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user