Debian Codegraph @

tools/pre-release.sh

raw
1 # This script creates releases on Github for micro
2 # You must have the correct Github access token to run this script
3
4 # $1 is the title, $2 is the description
5
6 commitID=$(git rev-parse HEAD)
7 tag="v$1"
8
9 echo "Creating tag"
10 git tag $tag $commitID
11 hub push --tags
12
13 echo "Cross compiling binaries"
14 ./cross-compile.sh $1
15 mv ../binaries .
16
17 NL=$'\n'
18
19 echo "Creating new release"
20 hub release create $tag \
21 --prerelease \
22 --message "$1${NL}${NL}$2" \
23 --attach "binaries/micro-$1-osx.tar.gz" \
24 --attach "binaries/micro-$1-macos-arm64.tar.gz" \
25 --attach "binaries/micro-$1-linux64.tar.gz" \
26 --attach "binaries/micro-$1-linux64-static.tar.gz" \
27 --attach "binaries/micro-$1-amd64.deb" \
28 --attach "binaries/micro-$1-linux32.tar.gz" \
29 --attach "binaries/micro-$1-linux-arm.tar.gz" \
30 --attach "binaries/micro-$1-linux-arm64.tar.gz" \
31 --attach "binaries/micro-$1-freebsd64.tar.gz" \
32 --attach "binaries/micro-$1-freebsd32.tar.gz" \
33 --attach "binaries/micro-$1-openbsd64.tar.gz" \
34 --attach "binaries/micro-$1-openbsd32.tar.gz" \
35 --attach "binaries/micro-$1-netbsd64.tar.gz" \
36 --attach "binaries/micro-$1-netbsd32.tar.gz" \
37 --attach "binaries/micro-$1-win64.zip" \
38 --attach "binaries/micro-$1-win32.zip"