This repository has been archived by the owner on Aug 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathMakefile
82 lines (64 loc) · 1.68 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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# build output folder
DIST_FOLDER = dist
BUILD_FOLDER = build
# extra test options
TEST_OPTS = ''
# Documentation
SPHINXOPTS =
SPHINXBUILD = sphinx-build
SOURCEDIR = docs
BUILDDIR = docs/_build
.PHONY: list
list:
@echo clean build lint test publish-test publish
default: build
build: build-dist
build-dist:
@echo build
poetry build
@echo done
install: build
@echo build and install the SDK
python -m pip install dist/$(shell ls -tr dist | grep whl | tail -1)
@echo installation completed
test: test-all
test-all:
@echo run pytest
pytest -v --junitxml test-results.xml tests --cov=aeternity --cov-config .coveragerc --cov-report xml:coverage.xml $(TEST_OPTS)
@echo done
lint: lint-all
lint-all:
@echo lint aeternity
flake8 aeternity
@echo done
clean:
@echo remove '$(DIST_FOLDER)','$(BUILD_FOLDER)' folders
@rm -rf $(DIST_FOLDER) $(BUILD_FOLDER)
@echo done
publish:
@echo publish on pypi.org
poetry publish --build
@echo done
publish-test:
@echo publish on test.pypi.org
poetry config repositories.testpypi https://test.pypi.org/legacy/
poetry publish --build --repository testpypi
@echo done
deps:
@echo generating requirements.txt
poetry export --dev -f requirements.txt > requirements.txt
@echo done
changelog:
@echo build changelog
git-changelog -t keepachangelog -s angular . -o CHANGELOG.md
@echo done
docs-html:
@echo build html documentation
$(SPHINXBUILD) -M html "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@echo done
docs-view: docs-html
python -c "import webbrowser; webbrowser.open('docs/_build/html/index.html')"
docs-lint:
@echo lint documentation
$(SPHINXBUILD) -M linkcheck "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@echo done