-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
60 lines (44 loc) · 1.25 KB
/
Makefile
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
V=$(shell git describe --tags --abbrev=0 | sed "s/v//")
USERNAME='__token__'
PASSWORD='foo'
poetry.install:
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true
poetry config virtualenvs.path .
poetry install
poetry.config.test_pypi_repo:
poetry config repositories.testpypi https://test.pypi.org/legacy/
poetry.config.test_pypi_token:
poetry config pypi-token.testpypi $(TOKEN)
poetry.config.native:
poetry config virtualenvs.create false
poetry.config.venv:
poetry config virtualenvs.create true
poetry config virtualenvs.in-project true
poetry config virtualenvs.path .
bump.version:
poetry version $(V)
sed 's/=.*/= "$(V)"/' -i py_bdd_context/__init__.py
coverage:
coverage run -m unittest
coverage report
coverage xml
test:
python -m unittest $(args)
test.failure:
python -m unittest examples.failure
fmt:
black .
make fmt.check
fmt.check:
black --check .
flake8
package.build: bump.version
poetry build
package.publish.test:
poetry publish -r testpypi
package.publish:
poetry publish -u $(USERNAME) -p $(PASSWORD)
package.build_and_publish: package.build package.publish
install.test:
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ py-bdd-context==$(V)