Commit 15878d1b authored by Nick Thomas's avatar Nick Thomas

Merge branch 'make-release' into 'master'

Add "make release" script

See merge request !99
parents 5aa350e3 fff333fb
...@@ -48,6 +48,9 @@ clean: clean-workhorse clean-build ...@@ -48,6 +48,9 @@ clean: clean-workhorse clean-build
clean-workhorse: clean-workhorse:
cd ${BUILD_DIR} && rm -f gitlab-workhorse gitlab-zip-cat gitlab-zip-metadata cd ${BUILD_DIR} && rm -f gitlab-workhorse gitlab-zip-cat gitlab-zip-metadata
release:
sh _support/release.sh
.PHONY: clean-build .PHONY: clean-build
clean-build: clean-build:
rm -rf ${BUILD_DIR}/_build rm -rf ${BUILD_DIR}/_build
set -e
remotes='https://dev.gitlab.org/gitlab/gitlab-workhorse.git https://gitlab.com/gitlab-org/gitlab-workhorse.git'
main() {
get_version
tag_name="v${version}"
git tag -m "Version ${version}" -a ${tag_name}
git show ${tag_name}
echo
echo "Does this look OK? Enter 'yes' to push to ${remotes}"
read confirmation
if [ "x${confirmation}" != xyes ] ; then
echo "Aborting"
exit 1
fi
for r in ${remotes}; do
git push "${r}" HEAD ${tag_name}
done
}
get_version() {
v=$(sed 1q VERSION)
if ! echo "${v}" | grep -q '^[0-9]\+\.[0-9]\+\.[0-9]\+$' ; then
echo "Invalid VERSION: ${v}"
exit 1
fi
version="${v}"
}
main
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment