aerkalov / ebooklib

Python E-book library for handling books in EPUB2/EPUB3 format -
https://ebooklib.readthedocs.io/
GNU Affero General Public License v3.0
1.49k stars 234 forks source link

Add a Github Workflow to check formatting with black and reformat files #321

Open ddaws opened 2 months ago

ddaws commented 2 months ago

This MR adds a CI check to ensure that all files are well formatted using Python black. To get the workflow passing I went ahead and reformatted all of the files using black.

I also investigated only checking files that have changed in the current branch to progressively reformat the repo, but this made the CI more complex and ultimately I dropped it and decided to just rip the :adhesive_bandage: off.

I hope this is helpful. Once this is merged I would be happy to continue to add workflow support for the steps listed in #318


Note: This MR is a bit easier to review if you hide whitespace changes

image