Merge pull request #9 from gdevillele/pr-update-makefile

update Makefile
This commit is contained in:
Daniel Nephin 2017-05-03 15:43:26 -04:00 committed by GitHub
commit 589afd2f50
2 changed files with 5 additions and 3 deletions

View File

@ -2,7 +2,7 @@
# github.com/docker/cli
#
.PHONY: build clean cross test lint
.PHONY: build clean test lint cross
# build the CLI
build: clean
@ -17,6 +17,7 @@ clean:
test:
@go test -tags daemon -v $(shell go list ./... | grep -v /vendor/)
# run linters
lint:
@gometalinter --config gometalinter.json ./...

View File

@ -4,7 +4,7 @@
# Makefile for developing using Docker
#
+.PHONY: build_docker_image build clean cross dev
+.PHONY: build_docker_image build_linter_image build clean test cross dev lint
DEV_DOCKER_IMAGE_NAME = docker-cli-dev
LINTER_IMAGE_NAME = docker-cli-lint
@ -37,7 +37,8 @@ cross: build_docker_image
# start container in interactive mode for in-container development
dev: build_docker_image
@docker run -ti $(MOUNTS) $(DEV_DOCKER_IMAGE_NAME) ash
@docker run -ti $(MOUNTS) -v /var/run/docker.sock:/var/run/docker.sock $(DEV_DOCKER_IMAGE_NAME) ash
# run linters in a container
lint: build_linter_image
@docker run -ti $(MOUNTS) $(LINTER_IMAGE_NAME)