synadm icon indicating copy to clipboard operation
synadm copied to clipboard

Integrate code-style checks into our CI

Open JOJ0 opened this issue 1 year ago • 2 comments

I'd like to introduce some code-style checks into the CI. I have learnt by contributing to github.com/beetbox/beets what a valuable feature this can be. They check using flake8 via tox, so this might not be the right approach for us: https://github.com/beetbox/beets/blob/master/.github/workflows/ci.yaml#L116-L117

I'd definitely want to use flake8 but it might be a simple solution like pip-installing during our gh-actions workflow run and then just executing flake8 from cli for all our files/the whole repo. Would require some trial and error approaches to get ir right so it makes sense and is informational to the contributor.

Furthermore, proper excludes of certain errors and warnings will most probably be required. Not every single pep8/flake8 thing might be suitable for our project.

JOJ0 avatar Sep 19 '22 06:09 JOJ0

Might help: https://github.com/marketplace/actions/flake8-action

JOJ0 avatar Sep 28 '22 09:09 JOJ0

flake8 docs, excluding violations: https://flake8.pycqa.org/en/latest/user/violations.html

JOJ0 avatar Sep 29 '22 09:09 JOJ0