windows: Replace symlinks with files for TSX Tree-sitter queries (#13893)

Previously to these changes, as stated in the issue, when someone tried
to use TSX as language for the file, the language was not set and it
disappeared from the selectable language list. This was due to the fact
that that the three files were symlinks, and windows couldn't read them.
I replaced them with normal files.

Fixes #12208.

Release Notes:

- N/A

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
This commit is contained in:
Ghostylab 2024-07-08 16:32:20 +02:00 committed by GitHub
parent c5e5add094
commit 7f50055d70
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 96 additions and 3 deletions

View File

@ -1 +0,0 @@
../typescript/brackets.scm

View File

@ -0,0 +1,5 @@
("(" @open ")" @close)
("[" @open "]" @close)
("{" @open "}" @close)
("<" @open ">" @close)
("\"" @open "\"" @close)

View File

@ -1 +0,0 @@
../typescript/indents.scm

View File

@ -0,0 +1,15 @@
[
(call_expression)
(assignment_expression)
(member_expression)
(lexical_declaration)
(variable_declaration)
(assignment_expression)
(if_statement)
(for_statement)
] @indent
(_ "[" "]" @end) @indent
(_ "<" ">" @end) @indent
(_ "{" "}" @end) @indent
(_ "(" ")" @end) @indent

View File

@ -1 +0,0 @@
../typescript/outline.scm

View File

@ -0,0 +1,76 @@
(internal_module
"namespace" @context
name: (_) @name) @item
(enum_declaration
"enum" @context
name: (_) @name) @item
(type_alias_declaration
"type" @context
name: (_) @name) @item
(function_declaration
"async"? @context
"function" @context
name: (_) @name
parameters: (formal_parameters
"(" @context
")" @context)) @item
(interface_declaration
"interface" @context
name: (_) @name) @item
(export_statement
(lexical_declaration
["let" "const"] @context
(variable_declarator
name: (_) @name) @item))
(program
(lexical_declaration
["let" "const"] @context
(variable_declarator
name: (_) @name) @item))
(class_declaration
"class" @context
name: (_) @name) @item
(method_definition
[
"get"
"set"
"async"
"*"
"readonly"
"static"
(override_modifier)
(accessibility_modifier)
]* @context
name: (_) @name
parameters: (formal_parameters
"(" @context
")" @context)) @item
(public_field_definition
[
"declare"
"readonly"
"abstract"
"static"
(accessibility_modifier)
]* @context
name: (_) @name) @item
; Add support for (node:test, bun:test and Jest) runnable
(call_expression
function: (_) @context
(#any-of? @context "it" "test" "describe")
arguments: (
arguments . (string
(string_fragment) @name
)
)
) @item