Skip to content

Commit

Permalink
feat: add black formatter to CI
Browse files Browse the repository at this point in the history
This change is needed to ensure that the codebase is formatted
consistently and follows the black formatter guidelines. This will help
improve code readability and maintainability.

This change adds a GitHub Actions workflow that runs the
black formatter on every push and pull request. The workflow uses the
rickstaa/action-black@v1 action to format the codebase and the
stefanzweifel/git-auto-commit-action@v5 action to automatically
commit the changes.

N/A
  • Loading branch information
keonly committed Oct 10, 2023
1 parent 2cdc588 commit 5b4f2dc
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/format-black.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Format with black
on: [push, pull_request]

jobs:
format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Format files using the black formatter
uses: rickstaa/action-black@v1
id: action_black
with:
black_args: "."
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: Formatted with black

0 comments on commit 5b4f2dc

Please sign in to comment.