Skip to content

Commit a948093

Browse files
committed
Replace pre-commit with tox for black
1 parent 1d95d1b commit a948093

File tree

3 files changed

+16
-7
lines changed

3 files changed

+16
-7
lines changed

.pre-commit-config.yaml

-6
This file was deleted.

.travis.yml

+9
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@ jobs:
1010
addons: skip
1111
env: TOXENV=flake8
1212

13+
-
14+
name: Formatting
15+
python: 3.7
16+
dist: xenial
17+
sudo: required
18+
before_install: skip
19+
addons: skip
20+
env: TOXENV=black
21+
1322
-
1423
name: Docs
1524
python: 3.7

tox.ini

+7-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# and then run "tox" from this directory.
55

66
[tox]
7-
envlist = py{27,36,37,py,py3}, docs, flake8
7+
envlist = py{27,36,37,py,py3}, docs, flake8, black
88

99
[testenv]
1010
passenv = PYTEST_ADDOPTS
@@ -28,6 +28,12 @@ basepython = python
2828
deps = flake8
2929
commands = flake8 {posargs:.}
3030

31+
[testenv:black]
32+
skip_install = true
33+
basepython = python
34+
deps = black
35+
commands = black --check {posargs:.}
36+
3137
[flake8]
3238
max-line-length = 88
3339
exclude = .eggs,.tox,docs

0 commit comments

Comments
 (0)