mirror of
https://github.com/coredns/coredns.git
synced 2025-10-28 16:54:15 -04:00
Makefile.release: bogus all target (#666)
Make the default target do nothing and put the actual release under a 'release' target. Prevent accidentally committing unwanted commits to the repo. Tested with `make -f Makefile.release -n`.
This commit is contained in:
@@ -23,7 +23,7 @@
|
|||||||
# * Get an access token: https://help.github.com/articles/creating-an-access-token-for-command-line-use/
|
# * Get an access token: https://help.github.com/articles/creating-an-access-token-for-command-line-use/
|
||||||
# * export GITHUB_ACCESS_TOKEN=<token>
|
# * export GITHUB_ACCESS_TOKEN=<token>
|
||||||
# * Up the version in coremain/version.go
|
# * Up the version in coremain/version.go
|
||||||
# * Run: make -f Makefile.release
|
# * Run: make -f Makefile.release release
|
||||||
# * will commit your change with 'Release $VERSION'
|
# * will commit your change with 'Release $VERSION'
|
||||||
# * push to github
|
# * push to github
|
||||||
# * build the release and do all that fluff.
|
# * build the release and do all that fluff.
|
||||||
@@ -41,9 +41,12 @@ GITHUB:=coredns
|
|||||||
DOCKER:=coredns
|
DOCKER:=coredns
|
||||||
DOCKER_IMAGE_NAME:=$(DOCKER)/$(NAME)
|
DOCKER_IMAGE_NAME:=$(DOCKER)/$(NAME)
|
||||||
|
|
||||||
all: commit push build tar release
|
all:
|
||||||
|
@echo Use the 'release' target to start a release
|
||||||
|
|
||||||
docker: docker-build docker-release
|
release: commit push build tar upload
|
||||||
|
|
||||||
|
docker: docker-build docker-upload
|
||||||
|
|
||||||
.PHONY: push
|
.PHONY: push
|
||||||
push:
|
push:
|
||||||
@@ -81,8 +84,8 @@ tar:
|
|||||||
tar -zcf release/$(NAME)_$(VERSION)_linux_armv6l.tgz -C build/Linux/Arm $(NAME)
|
tar -zcf release/$(NAME)_$(VERSION)_linux_armv6l.tgz -C build/Linux/Arm $(NAME)
|
||||||
tar -zcf release/$(NAME)_$(VERSION)_darwin_$(ARCH).tgz -C build/Darwin $(NAME)
|
tar -zcf release/$(NAME)_$(VERSION)_darwin_$(ARCH).tgz -C build/Darwin $(NAME)
|
||||||
|
|
||||||
.PHONY: release
|
.PHONY: upload
|
||||||
release:
|
upload:
|
||||||
@echo Releasing: $(VERSION)
|
@echo Releasing: $(VERSION)
|
||||||
gh-release create $(GITHUB)/$(NAME) $(VERSION)
|
gh-release create $(GITHUB)/$(NAME) $(VERSION)
|
||||||
|
|
||||||
@@ -92,8 +95,8 @@ docker:
|
|||||||
docker build -t $(DOCKER_IMAGE_NAME) .
|
docker build -t $(DOCKER_IMAGE_NAME) .
|
||||||
docker tag $(DOCKER_IMAGE_NAME):latest $(DOCKER_IMAGE_NAME):$(VERSION)
|
docker tag $(DOCKER_IMAGE_NAME):latest $(DOCKER_IMAGE_NAME):$(VERSION)
|
||||||
|
|
||||||
.PHONY: docker-release
|
.PHONY: docker-upload
|
||||||
docker-release:
|
docker-upload:
|
||||||
@echo Pushing: $(VERSION)
|
@echo Pushing: $(VERSION)
|
||||||
docker tag $(DOCKER_IMAGE_NAME):latest $(DOCKER_IMAGE_NAME):$(VERSION)
|
docker tag $(DOCKER_IMAGE_NAME):latest $(DOCKER_IMAGE_NAME):$(VERSION)
|
||||||
docker push $(DOCKER_IMAGE_NAME):latest
|
docker push $(DOCKER_IMAGE_NAME):latest
|
||||||
|
|||||||
Reference in New Issue
Block a user