Skip to content

Commit

Permalink
build(core): Add more python format tools
Browse files Browse the repository at this point in the history
  • Loading branch information
fangyinc committed Dec 23, 2023
1 parent a92321d commit 904aeda
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
13 changes: 13 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,20 @@ testenv: setup ## Set up the Python test environment

.PHONY: fmt
fmt: setup ## Format Python code
# TODO: Use isort to sort Python imports.
# https://github.com/PyCQA/isort
# $(VENV_BIN)/isort .
# https://github.com/psf/black
$(VENV_BIN)/black .
# TODO: Use blackdoc to format Python doctests.
# https://blackdoc.readthedocs.io/en/latest/
# $(VENV_BIN)/blackdoc .
# TODO: Type checking of Python code.
# https://github.com/python/mypy
# $(VENV_BIN)/mypy dbgpt
# TODO: uUse flake8 to enforce Python style guide.
# https://flake8.pycqa.org/en/latest/
# $(VENV_BIN)/flake8 dbgpt

.PHONY: pre-commit
pre-commit: fmt test ## Run formatting and unit tests before committing
Expand Down
4 changes: 3 additions & 1 deletion requirements/dev-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ pytest-recording
pytesseract==0.3.10
aioresponses
# for git hooks
pre-commit
pre-commit
# Type checking
mypy==0.991

0 comments on commit 904aeda

Please sign in to comment.