-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile
56 lines (38 loc) · 1.2 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
ARGS?=--help
ifdef DEBUG
TWINE_ARGS+=--repository-url "https://test.pypi.org/legacy/"
endif
.PHONY: run
run: | venv
$(VENV)/cirrus-run $(ARGS)
.PHONY: test
REQUIREMENTS_TXT+=tests/requirements.txt
test: | venv
$(VENV)/pytest $(PYTEST_ARGS)
.PHONY: test-job test-job-yml test-job-star
test-job: test-job-yml
test-job-yml test-job-star: | venv
$(VENV)/cirrus-run tests/sample_build_config.$(subst test-job-,,$@) -vvvv --show-build-log=always
include Makefile.venv
Makefile.venv:
curl \
-o Makefile.fetched \
-L "https://github.com/sio/Makefile.venv/raw/v2020.02.26/Makefile.venv"
echo "e0aeebe87c811fd9dfd892d4debb813262646e3e82691e8c4c214197c4ab6fac *Makefile.fetched" \
| sha256sum --check - \
&& mv Makefile.fetched Makefile.venv
.PHONY: package
package: | venv
-rm -rv dist
$(VENV)/python setup.py sdist
.PHONY: upload
upload: package $(VENV)/twine
$(VENV)/twine upload $(TWINE_ARGS) dist/*
.PHONY: debug/build_status
debug/build_status: | venv
$(VENV)/python $@.py $(DEBUG_BUILD_ID)
.PHONY: debug/find_multiple_tasks
debug/find_multiple_tasks: export CIRRUS_GITHUB_REPO?=libvirt/libvirt
debug/find_multiple_tasks: export CIRRUS_API_TOKEN?=" "
debug/find_multiple_tasks:
$(VENV)/python $@.py