A customisable GitHub action to check the style of Python code with black.
You can use inputs to alter how black
will check your code.
This tells black
where to look for files to check.
Default: .
, i.e. looks for files in the whole repository.
This tells black
how long each line of Python code can be.
Default: 81
, which is different from black
's default of 88
.
Include this in your .github/workflows/main.yaml
:
uses: RojerGS/python-black-check@master
or, if you want to override any of the defaults,
uses: RojerGS/python-black-check@master
with:
line-length: '81'
path: '.'