diff --git a/Makefile b/Makefile index 2d2e1ed7..28081659 100644 --- a/Makefile +++ b/Makefile @@ -34,11 +34,11 @@ clean-build: @rm -fr dist/ @rm -fr *.egg-info -format fmt: - isort --recursive oauthlib tests +format fmt black: + black . -lint: - isort --recursive --check-only --diff oauthlib tests +lint ruff: + ruff . test: tox @@ -81,4 +81,4 @@ dance: .DEFAULT_GOAL := all .PHONY: clean test bottle dance django flask requests -all: test bottle dance django flask requests +all: lint test bottle dance django flask requests diff --git a/tox.ini b/tox.ini index 229dd9df..fb476a12 100644 --- a/tox.ini +++ b/tox.ini @@ -1,6 +1,6 @@ # require tox>=4 [tox] -envlist = py38,py39,py310,py311,py312,pypy3,docs,readme,bandit,isort +envlist = py38,py39,py310,py311,py312,pypy3,docs,readme,ruff [testenv] deps= @@ -9,7 +9,6 @@ commands= pytest --cov=oauthlib tests/ # tox -e docs to mimic readthedocs build. -# as of today, RTD is using python3.7 and doesn't run "setup.py install" [testenv:docs] basepython=python3.11 skipsdist=True @@ -28,16 +27,8 @@ allowlist_externals=echo commands= twine check .tox/.pkg/dist/* -[testenv:bandit] -basepython=python3.11 -skipsdist=True -deps=bandit -commands=bandit -b bandit.json -r oauthlib/ -allowlist_externals=bandit - -[testenv:isort] -basepython = python3.8 -usedevelop = false -deps = isort -changedir = {toxinidir} -commands = isort --recursive --check-only --diff oauthlib tests +[testenv:ruff] +deps=ruff +allowlist_externals=ruff +skip_install=true +commands=ruff .