2015-09-22 16:10:11 +02:00
|
|
|
#!/bin/bash
|
|
|
|
#
|
|
|
|
# Build the release binaries
|
|
|
|
#
|
|
|
|
|
|
|
|
. "$(dirname "${BASH_SOURCE[0]}")/utils.sh"
|
|
|
|
|
2015-10-06 21:18:58 +02:00
|
|
|
function usage() {
|
|
|
|
>&2 cat << EOM
|
|
|
|
Build binaries for the release.
|
|
|
|
|
|
|
|
This script requires that 'git config branch.${BRANCH}.release' is set to the
|
|
|
|
release version for the release branch.
|
|
|
|
|
|
|
|
EOM
|
|
|
|
exit 1
|
|
|
|
}
|
|
|
|
|
|
|
|
BRANCH="$(git rev-parse --abbrev-ref HEAD)"
|
|
|
|
VERSION="$(git config "branch.${BRANCH}.release")" || usage
|
2015-09-22 16:10:11 +02:00
|
|
|
REPO=docker/compose
|
|
|
|
|
|
|
|
# Build the binaries
|
|
|
|
script/clean
|
2016-01-15 22:27:43 +01:00
|
|
|
script/build/linux
|
2015-09-22 16:10:11 +02:00
|
|
|
# TODO: build osx binary
|
2016-01-15 22:35:26 +01:00
|
|
|
# script/setup/osx
|
2016-01-15 22:27:43 +01:00
|
|
|
# script/build/osx
|
2015-09-22 16:10:11 +02:00
|
|
|
# TODO: build or fetch the windows binary
|
|
|
|
echo "You need to build the osx/windows binaries, that step is not automated yet."
|
|
|
|
|
2015-10-06 21:18:58 +02:00
|
|
|
echo "Building the container distribution"
|
2016-01-15 22:27:43 +01:00
|
|
|
script/build/image $VERSION
|
2015-10-06 21:18:58 +02:00
|
|
|
|
2015-09-22 16:10:11 +02:00
|
|
|
echo "Create a github release"
|
|
|
|
# TODO: script more of this https://developer.github.com/v3/repos/releases/
|
|
|
|
browser https://github.com/$REPO/releases/new
|