-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
37 lines (31 loc) · 832 Bytes
/
Copy pathMakefile
File metadata and controls
37 lines (31 loc) · 832 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
##
# Gammy
#
# @file
#
SHELL := /bin/bash
.PHONY: install
install:
pip install -r requirements.txt
pip install -e .
.PHONY: test
test:
pytest -v
python3 -m doctest -v README.md
.PHONY: pip-compile
pip-compile:
pip-compile --resolver=backtracking \
--verbose \
--extra=test,dev \
--output-file=requirements.txt ./setup.cfg
.PHONY: release
release:
@python3 -c "import gammy; print(f'Current version: {gammy.__version__}')"
@read -p "Enter new version (X.Y.Z): " version && \
sed -i "s/version = .*/version = $$version/g" ./setup.cfg && \
echo "__version__ = '$$version'" > ./gammy/__version__.py
make test
python3 -m build
@read -s -p "PyPI secret: " password && echo && \
python3 -m twine upload dist/* --repository-url https://upload.pypi.org/legacy/ --username __token__ --password $$password
# end