mirror of
https://github.com/Dev-Wiki/git-repo.git
synced 2025-12-16 11:20:27 +08:00
Make black with line length 80 repo's code style
Provide a consistent formatting style and tox commands to lint and format. Bug: b/267675342 Change-Id: I33ddfe07af8473f4334c347d156246bfb66d4cfe Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/362954 Reviewed-by: Josip Sokcevic <sokcevic@google.com> Reviewed-by: Mike Frysinger <vapier@google.com> Tested-by: Gavin Mak <gavinmak@google.com> Commit-Queue: Gavin Mak <gavinmak@google.com>
This commit is contained in:
20
tox.ini
20
tox.ini
@@ -15,7 +15,7 @@
|
||||
# https://tox.readthedocs.io/
|
||||
|
||||
[tox]
|
||||
envlist = py36, py37, py38, py39, py310
|
||||
envlist = lint, py36, py37, py38, py39, py310
|
||||
|
||||
[gh-actions]
|
||||
python =
|
||||
@@ -35,5 +35,23 @@ setenv =
|
||||
GIT_COMMITTER_NAME = Repo test committer
|
||||
EMAIL = repo@gerrit.nodomain
|
||||
|
||||
[testenv:lint]
|
||||
skip_install = true
|
||||
deps =
|
||||
black
|
||||
flake8
|
||||
commands =
|
||||
black --check {posargs:.}
|
||||
flake8
|
||||
|
||||
[testenv:format]
|
||||
skip_install = true
|
||||
deps =
|
||||
black
|
||||
flake8
|
||||
commands =
|
||||
black {posargs:.}
|
||||
flake8
|
||||
|
||||
[pytest]
|
||||
timeout = 300
|
||||
|
||||
Reference in New Issue
Block a user