-
Notifications
You must be signed in to change notification settings - Fork 2.2k
scripts/build: add a python script for checking style rules #14111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
And ironically, it’s a Python script with no final newline… |
I'm aware that I get this constantly wrong, that's why I asked and then wrote this script. |
I've changed it to use no external dependencies and to post a single review with multiple comments, fixing any rate limit issues before they appear. I've tested the style checker against #14020 here: |
I realize this is in direct competition with #14107, I started work on this on saturday when I posted the question if this could be automated in the Discord server.
The action will post code reviews, much like a human reviwer would.
An example can be seen here: stonedDiscord#5
I went through https://docs.mamedev.org/contributing/cxx.html to come up with these rules.
It will detect
It mostly uses regex to detect those, I haven't run into any false positives yet, but I'm on the fence about dropping the constants check because it will complain about variables that someone has marked const.