From 3361df2fff90d085c0048ab809dac7a236f4d015 Mon Sep 17 00:00:00 2001 From: evan Date: Thu, 29 Feb 2024 01:13:48 -0600 Subject: [PATCH] add file lock target --- Makefile | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 6faa2416..e67407c9 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,5 @@ .ONESHELL: +.SHELLFLAGS = -ec .SILENT: version := $(shell python -c "import tomllib;print(tomllib.load(open('pyproject.toml', 'rb'))['project']['version'])") @@ -7,7 +8,7 @@ dist: python -m build .PHONY: release -release: dist +release: tests dist # check that changelog is updated if ! grep ${version} CHANGELOG.rst then @@ -17,6 +18,21 @@ release: dist twine upload dist/pykeepass-$(version)* gh release create pykeepass-$(version) dist/pykeepass-$(version)* +.PHONY: tests +tests: + python tests/tests.py + +.PHONY: lock +lock: + # make a requirements.txt lockfile + rm -rf .venv_lock + virtualenv .venv_lock + source .venv_lock/bin/activate + pip install . + python tests/tests.py + pip freeze > requirements.txt + + .PHONY: docs docs: lazydocs pykeepass --overview-file README.md