zig: Fix syntax and file types (#11409)

Fixed autoclosing and made it recognize all ZON (Zig Object Notation)
files.

- Fixed single and double quotes not autoclosing for zig
- Fixed ZON file recognition
- Removed angle brackets autoclosing in zig as they are not used

Release Notes:

- N/A
This commit is contained in:
vali-pnt 2024-05-06 19:33:44 +03:00 committed by GitHub
parent 0aab6d8bdc
commit b25eb9afe2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,11 +1,12 @@
name = "Zig" name = "Zig"
grammar = "zig" grammar = "zig"
path_suffixes = ["zig", "zig.zon"] path_suffixes = ["zig", "zon"]
line_comments = ["// "] line_comments = ["// "]
autoclose_before = ";:.,=}])>" autoclose_before = ";:.,=}])"
brackets = [ brackets = [
{ start = "{", end = "}", close = true, newline = true }, { start = "{", end = "}", close = true, newline = true },
{ start = "[", end = "]", close = true, newline = true }, { start = "[", end = "]", close = true, newline = true },
{ start = "(", end = ")", close = true, newline = true }, { start = "(", end = ")", close = true, newline = true },
{ start = "<", end = ">", close = true, newline = true }, { start = "\"", end = "\"", close = true, newline = false, not_in = ["string"] },
{ start = "'", end = "'", close = true, newline = false, not_in = ["string", "comment"] },
] ]