Closed lildude closed 6 years ago
thanks, merged
do you have any recommendations for setting up CI to check if the grammar is valid?
thanks, merged
Woohoo!!! π. Thanks.
do you have any recommendations for setting up CI to check if the grammar is valid?
Unfortunately not. TextMate didn't seem to think of automated testing when it came to allowing people to write their own grammars so haven't really provided any guidelines or native methods to do so.
Our grammar compiler only really does basic key and syntax checking. You may be able to adapt this for your own purposes.
π from the Linguist community.
If you're not already aware, this grammar is included in GitHub Linguist which is used for syntax highlighting ABAP on GitHub.com.
I'm the primary GitHub maintainer and am in the process of creating a new Linguist release (which involved pulling the latest version of this repo) when I noticed that your grammar has changed such that our grammar compiler has detected a problem that prevents the grammar from being compiled:
This is the regex on line 50:
https://github.com/pvl/abap.tmbundle/blob/221919d83c0342332e4b42c473cfd598ae0565f2/Syntaxes/ABAP.tmLanguage#L50
... introduced in https://github.com/pvl/abap.tmbundle/pull/14.
The problem?
<
is not valid in an XML document and should be encoded.This PR does just that and encodes
<
to<
.If you're quick to merge this, I can ensure it's included in the next release of Linguist and thus GitHub.com.