release improvements (#1439)

Last release I forgot steps, put them in Makefile.release. Generating
the manual files will be skipped if 'ronn' can't be found.
This commit is contained in:
Miek Gieben
2018-01-26 16:57:08 +00:00
committed by Yong Tang
parent 4b5fc3002e
commit ed02f5f2a2
2 changed files with 18 additions and 4 deletions

View File

@@ -6,7 +6,13 @@ READMES:=$(subst /README.md,,$(READMES))
PLUGINS:=$(subst plugin/,corendns-,$(PLUGINS))
PLUGINS:=$(subst /README.md,(7),$(PLUGINS))
ifeq (, $(shell which ronn))
$(warning "No ronn in $$PATH, exiting")
all:
@echo "noop"
else
all: man/coredns.1 man/corefile.5 plugins
endif
man/coredns.1: coredns.1.md
sed -e 's/^\(#.*\)/\U\1/' $< > $@.md

View File

@@ -21,8 +21,11 @@
# * Get an access token: https://help.github.com/articles/creating-an-access-token-for-command-line-use/
# * export GITHUB_ACCESS_TOKEN=<token>
# * Up the version in coremain/version.go
# * Run: make -f Makefile.release release
# * will *commit* your change with 'Release $VERSION'
# * Run: make DOCKER=coredns -f Makefile.release release
# * runs make -f Makefile.doc
# * this is a noop if ronn can't be found
# * perform a go generate
# * will *commit* your change(s) with 'Release $VERSION'
# * push to github
# * build the release and do all that fluff.
#
@@ -61,16 +64,21 @@ LINUX_ARCH:=amd64 arm arm64 ppc64le s390x
PLATFORMS:=$(subst $(SPACE),$(COMMA),$(foreach arch,$(LINUX_ARCH),linux/$(arch)))
ifeq ($(DOCKER),)
$(error "Please specify Docker registry to use. Use \"coredns\" for releases")
$(error "Please specify Docker registry to use. Use DOCKER=coredns for releases")
endif
all:
@echo Use the 'release' target to start a release
release: commit push build tar upload
release: pre commit push build tar upload
docker: docker-build docker-push
.PHONY: pre
pre:
go generate
$(MAKE) -f Makefile.doc
.PHONY: push
push:
@echo Pushing release to master