Trailing thing
This commit is contained in:
parent
a99b3ecb70
commit
e4a8ad7b76
1 changed files with 2 additions and 1 deletions
|
|
@ -217,6 +217,7 @@ def emit_tree_sitter_grammar(grammar: parser.Grammar, path: pathlib.Path | str):
|
|||
with open(path, "w", encoding="utf-8") as f:
|
||||
f.write('/// <reference types="tree-sitter-cli/dsl" />\n')
|
||||
f.write("// @ts-check\n")
|
||||
f.write("// NOTE: This file was generated by a tool. Do not modify.\n")
|
||||
f.write("\n")
|
||||
f.write("module.exports = grammar({\n")
|
||||
f.write(f" name: '{grammar.name}',\n")
|
||||
|
|
@ -235,5 +236,5 @@ def emit_tree_sitter_grammar(grammar: parser.Grammar, path: pathlib.Path | str):
|
|||
|
||||
f.write(f" '{rule_name}': $ => {rule_definition},")
|
||||
|
||||
f.write(" }\n")
|
||||
f.write("\n }\n")
|
||||
f.write("});")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue