Skip to content

Commit df50df3

Browse files
authored
Merge pull request #1191 from bfirsh/fix-makefile-phony
Add .PHONY for each makefile instruction
2 parents 717ec94 + 0648923 commit df50df3

File tree

1 file changed

+15
-2
lines changed

1 file changed

+15
-2
lines changed

Makefile

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,47 @@
1-
.PHONY: all build test integration-test unit-test build-py3 unit-test-py3 integration-test-py3
2-
1+
.PHONY: all
32
all: test
43

4+
.PHONY: clean
55
clean:
66
-docker rm -vf dpy-dind
77
find -name "__pycache__" | xargs rm -rf
88

9+
.PHONY: build
910
build:
1011
docker build -t docker-py .
1112

13+
.PHONY: build-py3
1214
build-py3:
1315
docker build -t docker-py3 -f Dockerfile-py3 .
1416

17+
.PHONY: build-docs
1518
build-docs:
1619
docker build -t docker-py-docs -f Dockerfile-docs .
1720

21+
.PHONY: build-dind-certs
1822
build-dind-certs:
1923
docker build -t dpy-dind-certs -f tests/Dockerfile-dind-certs .
2024

25+
.PHONY: test
2126
test: flake8 unit-test unit-test-py3 integration-dind integration-dind-ssl
2227

28+
.PHONY: unit-test
2329
unit-test: build
2430
docker run docker-py py.test tests/unit
2531

32+
.PHONY: unit-test-py3
2633
unit-test-py3: build-py3
2734
docker run docker-py3 py.test tests/unit
2835

36+
.PHONY: integration-test
2937
integration-test: build
3038
docker run -v /var/run/docker.sock:/var/run/docker.sock docker-py py.test tests/integration
3139

40+
.PHONY: integration-test-py3
3241
integration-test-py3: build-py3
3342
docker run -v /var/run/docker.sock:/var/run/docker.sock docker-py3 py.test tests/integration
3443

44+
.PHONY: integration-dind
3545
integration-dind: build build-py3
3646
docker rm -vf dpy-dind || :
3747
docker run -d --name dpy-dind --privileged dockerswarm/dind:1.12.0 docker daemon\
@@ -42,6 +52,7 @@ integration-dind: build build-py3
4252
py.test tests/integration
4353
docker rm -vf dpy-dind
4454

55+
.PHONY: integration-dind-ssl
4556
integration-dind-ssl: build-dind-certs build build-py3
4657
docker run -d --name dpy-dind-certs dpy-dind-certs
4758
docker run -d --env="DOCKER_HOST=tcp://localhost:2375" --env="DOCKER_TLS_VERIFY=1"\
@@ -57,8 +68,10 @@ integration-dind-ssl: build-dind-certs build build-py3
5768
--link=dpy-dind-ssl:docker docker-py3 py.test tests/integration
5869
docker rm -vf dpy-dind-ssl dpy-dind-certs
5970

71+
.PHONY: flake8
6072
flake8: build
6173
docker run docker-py flake8 docker tests
6274

75+
.PHONY: docs
6376
docs: build-docs
6477
docker run -v `pwd`/docs:/home/docker-py/docs/ -p 8000:8000 docker-py-docs mkdocs serve -a 0.0.0.0:8000

0 commit comments

Comments
 (0)