2017-07-16 11:57:32 -07:00
|
|
|
#!/bin/bash
|
|
|
|
VERSION=$(git describe --tags)
|
2017-07-16 12:05:29 -07:00
|
|
|
mkdir ci/binaries
|
|
|
|
go build -x -ldflags "-s -w -X main.githash=$(git log --pretty=format:'%h' -n 1)" -o ci/binaries/matterbridge-$VERSION-$GOOS-$GOARCH
|
2017-07-16 11:57:32 -07:00
|
|
|
cd ci
|
|
|
|
cat > deploy.json <<EOF
|
|
|
|
{
|
|
|
|
"package": {
|
|
|
|
"name": "Matterbridge",
|
|
|
|
"repo": "nightly",
|
|
|
|
"subject": "42wim"
|
|
|
|
},
|
|
|
|
"version": {
|
|
|
|
"name": "$VERSION-$GOOS-$GOARCH"
|
|
|
|
},
|
|
|
|
"files":
|
|
|
|
[
|
2017-07-16 12:05:29 -07:00
|
|
|
{"includePattern": "binaries/(.*)", "uploadPattern":"\$1"}
|
2017-07-16 11:57:32 -07:00
|
|
|
],
|
|
|
|
"publish": true
|
|
|
|
}
|
|
|
|
EOF
|
|
|
|
|