diff --git a/Makefile b/Makefile index fb060be4..bf5c18d0 100644 --- a/Makefile +++ b/Makefile @@ -51,15 +51,20 @@ monitor: .PHONY: release release: + exit 0 @if [[ ! "$(version)" =~ ^[0-9]+\.[0-9]+\.[0-9]+(-.+)?$$ ]]; then \ echo "Must provide semantic version as arg to make." ; \ echo "e.g. make release version=1.2.3-beta" ; \ exit 1 ; \ fi - @git diff --quiet || { echo "Git working directory is dirty." && exit 1 ; } + @git diff --quiet || { echo "Git working directory is dirty."; exit 1 ; } git tag -a v$(version) -m "Release v$(version)" git push origin v$(version) - git merge --ff-only v$(version) mapic-release-test + @echo -n "Release mist-api-connector? [y] " + @read ans && [ $${ans:-y} = y ] || { echo "Mapic release aborted, branch not fast-forwarded."; exit 1 ; } + + git checkout mapic-release-test + git merge --ff-only v$(version) git push origin mapic-release-test