updates on developer information (parsing with lark)

This commit is contained in:
Trilarion
2020-02-03 15:50:24 +01:00
parent 10625a854a
commit eeb20a670a
66 changed files with 354 additions and 104 deletions

17
code/grammar_listing.lark Normal file
View File

@ -0,0 +1,17 @@
start: header entries*
header: "# " name " (" number ")\n" _E
entries: "## " name " (" number ")\n" _E property+ _E
property: "- " _key ": " _value "\n"
_key: /(?! ).+?(?=:)(?<! )/ // key: everything until next ":", not beginning or ending with a space
_value: /.+(?<! )/ // everything until the end of the line, not ending with a space
name: /.+?(?= \()/ // developer name: everything until " ("
number: /[0-9]+/
COMMENT: /^\[comment\]: #.*$\n/m // [comment]: # xxx
_E: /^$\n/m // empty new line
%ignore COMMENT