Skip to content

Commit

Permalink
adds black formatting to release branch and circleCI check for format
Browse files Browse the repository at this point in the history
  • Loading branch information
ifrit98 committed Jul 25, 2023
1 parent af1f535 commit 143fa72
Show file tree
Hide file tree
Showing 202 changed files with 17,142 additions and 10,418 deletions.
39 changes: 39 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,43 @@ orbs:
# coveralls: coveralls/coveralls@1.0.6

jobs:

black:
resource_class: small
parameters:
python-version:
type: string
docker:
- image: cimg/python:<< parameters.python-version >>

steps:
- checkout

- restore_cache:
name: Restore cached black venv
keys:
- v1-pypi-py-black-<< parameters.python-version >>

- run:
name: Update & Activate black venv
command: |
python -m venv env/
. env/bin/activate
python -m pip install --upgrade pip
pip install black
- save_cache:
name: Save cached black venv
paths:
- "env/"
key: v1-pypi-py-black-<< parameters.python-version >>

- run:
name: Black format check
command: |
. env/bin/activate
python -m black --exclude '(env|venv|.eggs)' --check .
build-and-test:
resource_class: medium
parallelism: 2
Expand Down Expand Up @@ -168,6 +205,8 @@ jobs:
workflows:
pr-requirements:
jobs:
- black:
python-version: "3.8.12"
- build-and-test:
matrix:
parameters:
Expand Down
Loading

0 comments on commit 143fa72

Please sign in to comment.