加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Makefile 1.20 KB
一键复制 编辑 原始数据 按行查看 历史
猫神战之京 提交于 2021-03-07 16:04 . add room-member-bot
SOURCE_GLOB=$(wildcard examples/*.py examples/**/*.py)
#
# Huan(202003)
# F811: https://github.com/PyCQA/pyflakes/issues/320#issuecomment-469337000
#
IGNORE_PEP=E203,E221,E241,E272,E501,F811
.PHONY: all
all : clean lint
.PHONY: clean
clean:
rm -fr dist/* .pytype
.PHONY: lint
lint: pylint pycodestyle flake8 mypy
# disable: TODO list temporay
.PHONY: pylint
pylint:
pylint \
--load-plugins pylint_quotes \
--disable=W0511,R0801,cyclic-import \
$(SOURCE_GLOB)
.PHONY: pycodestyle
pycodestyle:
pycodestyle \
--statistics \
--count \
--ignore="${IGNORE_PEP}" \
$(SOURCE_GLOB)
.PHONY: flake8
flake8:
flake8 \
--ignore="${IGNORE_PEP}" \
$(SOURCE_GLOB)
.PHONY: mypy
mypy:
MYPYPATH=stubs/ mypy \
$(SOURCE_GLOB)
.PHONY: pytype
pytype:
pytype \
-V 3.8 \
--disable=import-error \
examples/
.PHONY: install
install:
pip3 install -r requirements.txt
pip3 install -r requirements-dev.txt
.PHONY: pytest
pytest:
pytest src/ tests/
.PHONY: test-unit
test-unit: pytest
.PHONY: test
test: lint pytest
.PHONY: check-python-version
check-python-version:
./scripts/check_python_version.py
.PHONY: dist
dist:
python3 setup.py sdist bdist_wheel
.PHONY: bot
bot:
python3 examples/ding-dong-bot.py
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化