forked from ungleich-public/cdist
Merge branch 'master' into 2.1
This commit is contained in:
commit
794e9e75e0
1 changed files with 22 additions and 18 deletions
40
Makefile
40
Makefile
|
@ -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-branch-merge: git-checkout-stable
|
||||||
current=$$(git rev-parse --abbrev-ref HEAD); \
|
git merge "$(CHANGELOG_VERSION)"
|
||||||
git checkout "$(GIT_DST_BRANCH)" && \
|
|
||||||
git merge "$(GIT_SRC_BRANCH)" && \
|
|
||||||
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-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
|
||||||
|
@ -210,8 +215,15 @@ git-release: git-tag git-branch-merge
|
||||||
################################################################################
|
################################################################################
|
||||||
# pypi
|
# pypi
|
||||||
#
|
#
|
||||||
pypi-release: man $(VERSION_FILE) git-tag
|
PYPI_FILE=.lock-pypi
|
||||||
|
|
||||||
|
pypi-release: $(PYPI_FILE)
|
||||||
|
|
||||||
|
$(PYPI_FILE): man $(VERSION_FILE)
|
||||||
|
make git-checkout-stable
|
||||||
python3 setup.py sdist upload
|
python3 setup.py sdist upload
|
||||||
|
touch $@
|
||||||
|
make git-checkout-current
|
||||||
|
|
||||||
################################################################################
|
################################################################################
|
||||||
# archlinux
|
# archlinux
|
||||||
|
@ -220,7 +232,7 @@ ARCHLINUXTAR=cdist-$(CHANGELOG_VERSION)-1.src.tar.gz
|
||||||
$(ARCHLINUXTAR): PKGBUILD pypi-release
|
$(ARCHLINUXTAR): PKGBUILD pypi-release
|
||||||
makepkg -c --source
|
makepkg -c --source
|
||||||
|
|
||||||
PKGBUILD: PKGBUILD.in
|
PKGBUILD: PKGBUILD.in $(VERSION_FILE)
|
||||||
./PKGBUILD.in
|
./PKGBUILD.in
|
||||||
|
|
||||||
archlinux-release: $(ARCHLINUXTAR)
|
archlinux-release: $(ARCHLINUXTAR)
|
||||||
|
@ -237,16 +249,8 @@ RELEASE+=ml-release freecode-release
|
||||||
RELEASE+=man-dist pypi-release git-release
|
RELEASE+=man-dist pypi-release git-release
|
||||||
RELEASE+=archlinux-release
|
RELEASE+=archlinux-release
|
||||||
|
|
||||||
release: $(RELEASE)
|
release: $(CHECKS) $(RELEASE)
|
||||||
echo "Don't forget...: linkedin"
|
echo "Manual steps: linkedin, twitter"
|
||||||
|
|
||||||
release-blog: blog
|
|
||||||
release-ml: release-blog
|
|
||||||
release-pub: man
|
|
||||||
|
|
||||||
|
|
||||||
$(DIST): dist-check
|
|
||||||
$(RELEASE): $(DIST) $(CHECKS)
|
|
||||||
|
|
||||||
# Code that is better handled in a shell script
|
# Code that is better handled in a shell script
|
||||||
check-%:
|
check-%:
|
||||||
|
|
Loading…
Reference in a new issue