forked from GoogleCloudPlatform/marketplace-k8s-app-tools
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
36 lines (31 loc) · 804 Bytes
/
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
### Images publishing ###
include marketplace.Makefile
include tests.Makefile
### Testing ###
.PHONY: lint/py
lint/py: .build/tests/py
@docker run --rm \
-v $(PWD):/data:ro \
--entrypoint python3 \
tests/py \
-m yapf --style yapf --recursive --diff \
--exclude "data/vendor/" \
--parallel \
"/data" \
|| (echo ">>> Linting failed. Run 'make format/py' to fix your code."; exit 1)
@docker run --rm \
-v $(PWD):/data:ro \
--entrypoint python3 \
tests/py \
-m pyflakes "/data"
@$(call print_notice,No lint errors found.)
.PHONY: format/py
format/py: .build/tests/py
@docker run --rm \
-v $(PWD):/data \
--entrypoint python3 \
tests/py \
-m yapf --style yapf --recursive --in-place \
--exclude "data/vendor/" \
--verbose --parallel \
"/data"