Skip to content

Commit

Permalink
move yapf config into pyproject.toml (#246)
Browse files Browse the repository at this point in the history
* move yapf config into pyproject.toml

* add toml as dependencies

* removed yapf-action

* fix
  • Loading branch information
hirosassa authored Sep 6, 2021
1 parent 5709a89 commit 49f23d8
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@ jobs:

steps:
- uses: actions/checkout@v2
- name: Install dependencies
run: |
pip install toml yapf
- name: run YAPF to test if python code is correctly formatted
uses: AlexanderMelde/yapf-action@master
with:
args: --verbose --style=yapf.ini --exclude=**/docs/*
run: |
yapf --diff --recursive --verbose --exclude=**/docs/* $GITHUB_WORKSPACE
- uses: actions/setup-python@v2
with:
python-version: 3.8
Expand Down
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ coverage = "*"
isort = "^5.7"
yapf = "^0.31"

[tool.yapf]
based_on_style = "pep8"
column_limit = 160

[tool.isort]
line_length = 160

Expand Down
3 changes: 0 additions & 3 deletions yapf.ini

This file was deleted.

0 comments on commit 49f23d8

Please sign in to comment.