move pypi releases to go from the stable branch only

Signed-off-by: Nico Schottelius <nico@bento.schottelius.org>
This commit is contained in:
Nico Schottelius 2013-07-09 18:02:32 +02:00
parent 511e7951c8
commit 02c8079fef

View file

@ -180,6 +180,7 @@ freecode-release: $(FREECODE_FILE)
GIT_TAG_FILE=.git/refs/tags/$(CHANGELOG_VERSION) GIT_TAG_FILE=.git/refs/tags/$(CHANGELOG_VERSION)
GIT_SRC_BRANCH=master GIT_SRC_BRANCH=master
GIT_DST_BRANCH=$(shell echo $(CHANGELOG_VERSION) | cut -d. -f '1,2') GIT_DST_BRANCH=$(shell echo $(CHANGELOG_VERSION) | cut -d. -f '1,2')
GIT_CURRENT=.git-current-branch
git-tag: $(GIT_TAG_FILE) git-tag: $(GIT_TAG_FILE)
@ -187,14 +188,18 @@ $(GIT_TAG_FILE):
@printf "Enter tag description for $(CHANGELOG_VERSION)> " @printf "Enter tag description for $(CHANGELOG_VERSION)> "
@read tagmessage; git tag "$(CHANGELOG_VERSION)" -m "$$tagmessage" @read tagmessage; git tag "$(CHANGELOG_VERSION)" -m "$$tagmessage"
git-branch-merge: git-tag git-branch-merge: git-checkout-stable
current=$$(git rev-parse --abbrev-ref HEAD); \ git merge "$(CHANGELOG_VERSION)"
git checkout "$(GIT_DST_BRANCH)" && \
git merge "$(CHANGELOG_VERSION)" && \
git checkout "$$current"
git-checkout-stable: git-tag
@git rev-parse --abbrev-ref HEAD > $(GIT_CURRENT)
@git checkout "$(GIT_DST_BRANCH)"
make git-checkout-current
$(VERSION_FILE): .git/refs/heads/* .git/refs/tags/* git-checkout-current:
git checkout "$$(cat $(GIT_CURRENT))"
$(VERSION_FILE): .git/refs/heads/* .git/refs/tags/* .git/HEAD
echo "VERSION = \"$$(git describe)\"" > $@ echo "VERSION = \"$$(git describe)\"" > $@
# Pub is Nico's "push to all git remotes" thing # Pub is Nico's "push to all git remotes" thing
@ -214,9 +219,11 @@ PYPI_FILE=.lock-pypi
pypi-release: $(PYPI_FILE) pypi-release: $(PYPI_FILE)
$(PYPI_FILE): man $(VERSION_FILE) git-tag $(PYPI_FILE): man $(VERSION_FILE)
make git-checkout-stable
python3 setup.py sdist upload python3 setup.py sdist upload
touch $@ touch $@
make git-checkout-current
################################################################################ ################################################################################
# archlinux # archlinux