1 Star 0 Fork 0

WaketZheng / aiopathlib

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
Makefile 1.34 KB
一键复制 编辑 原始数据 按行查看 历史
WaketZheng 提交于 2022-03-07 23:42 . Update Makefile and dependencies
checkfiles = aiopathlib/__init__.py tests/test_async.py tests/test_sync.py
black_opts = -l 88 -t py38
.PHONY: lint
.DEFAULT_GOAL := help
help:
@grep '^[a-zA-Z]' $(MAKEFILE_LIST) | sort | awk -F ':.*?## ' 'NF==2 {printf "\033[36m %-25s\033[0m %s\n", $$1, $$2}'
up: ## Update dependencies
poetry update
poetry export --dev --without-hashes > dev_requirements.txt
build: ## Build wheel and zip
rm -fR dist/
poetry build
publish: build
ifeq ($(shell which twine),)
pip install twine --user
endif
twine upload dist/*
lint: ## Reformat with isort and black, then check style with flake8 and mypy
isort $(checkfiles)
black $(black_opts) $(checkfiles)
flake8 $(checkfiles)
mypy $(checkfiles)
check: build ## Checks that build is sane
ifneq ($(shell which black),)
black --check $(black_opts) $(checkfiles) || (echo "Please run 'make style' to auto-fix style issues" && false)
endif
flake8 $(checkfiles)
mypy $(checkfiles)
bandit -r aiopathlib
twine check dist/*
style: ## Auto-formats the code
autoflake --in-place --remove-all-unused-imports $(checkfiles)
isort -src $(checkfiles)
black $(black_opts) $(checkfiles)
test: ## Test code with pytest and show coverage
coverage run -m pytest
coverage report -m
bump: ## Bump up version
ifeq ($(shell which bumpversion),)
pip install bumpversion
endif
bumpversion patch # major/minor/patch
git log -3
Python
1
https://gitee.com/waketzheng/aiopathlib.git
git@gitee.com:waketzheng/aiopathlib.git
waketzheng
aiopathlib
aiopathlib
master

搜索帮助