micro/tools/nightly-release.sh

34 lines
1.3 KiB
Bash
Raw Normal View History

2020-07-05 21:12:06 +00:00
# This script updates the nightly release on Github for micro
2020-02-16 00:33:49 +00:00
# Must be run from inside the micro git repository
2016-06-12 15:05:19 +00:00
2020-06-17 00:48:17 +00:00
commitID=$(git rev-parse --short HEAD)
go run remove-nightly-assets.go
2016-06-12 15:05:19 +00:00
echo "Cross compiling binaries"
./cross-compile.sh $1
mv ../binaries .
MESSAGE=$'Nightly build\n\nAutogenerated nightly build of micro'
2020-07-05 21:12:06 +00:00
echo "Updating release"
hub release edit nightly \
2020-02-16 00:33:49 +00:00
--prerelease \
2020-06-17 00:48:17 +00:00
--draft=false \
2020-07-05 21:12:06 +00:00
--message "$MESSAGE (please DISREGARD the creation date of this Github release). Assets uploaded on $(date) for commit $commitID." \
2020-02-16 00:33:49 +00:00
--attach "binaries/micro-$1-osx.tar.gz" \
--attach "binaries/micro-$1-linux64.tar.gz" \
--attach "binaries/micro-$1-linux64-static.tar.gz" \
2020-07-06 17:30:49 +00:00
--attach "binaries/micro-$1-amd64.deb" \
2020-02-16 00:33:49 +00:00
--attach "binaries/micro-$1-linux32.tar.gz" \
--attach "binaries/micro-$1-linux-arm.tar.gz" \
--attach "binaries/micro-$1-linux-arm64.tar.gz" \
--attach "binaries/micro-$1-freebsd64.tar.gz" \
--attach "binaries/micro-$1-freebsd32.tar.gz" \
--attach "binaries/micro-$1-openbsd64.tar.gz" \
--attach "binaries/micro-$1-openbsd32.tar.gz" \
--attach "binaries/micro-$1-netbsd64.tar.gz" \
--attach "binaries/micro-$1-netbsd32.tar.gz" \
--attach "binaries/micro-$1-win64.zip" \
--attach "binaries/micro-$1-win32.zip"