tendermint/scripts/publish.sh

21 lines
472 B
Bash
Raw Normal View History

2017-03-07 10:43:51 -08:00
#!/usr/bin/env bash
2017-06-02 20:20:02 -07:00
set -e
2017-03-07 10:43:51 -08:00
VERSION=$1
2017-06-02 20:20:02 -07:00
DIST_DIR=./build/dist
2017-03-07 10:43:51 -08:00
# Get the version from the environment, or try to figure it out.
if [ -z $VERSION ]; then
VERSION=$(awk -F\" '/Version =/ { print $2; exit }' < version/version.go)
fi
if [ -z "$VERSION" ]; then
echo "Please specify a version."
exit 1
fi
2017-09-26 03:46:36 -07:00
echo "==> Copying ${DIST_DIR} to S3..."
2017-03-07 10:43:51 -08:00
# copy to s3
2017-06-02 20:20:02 -07:00
aws s3 cp --recursive ${DIST_DIR} s3://tendermint/binaries/tendermint/v${VERSION} --acl public-read
2017-03-07 10:43:51 -08:00
exit 0