Skip to content
Snippets Groups Projects
Commit d8a38699 authored by stianst's avatar stianst Committed by Stian Thorgersen
Browse files

Added release script

parent f06cec4a
No related branches found
No related tags found
No related merge requests found
...@@ -30,7 +30,7 @@ build: golang ...@@ -30,7 +30,7 @@ build: golang
release: clean golang deps release: clean golang deps
@mkdir -p release @mkdir -p release
$(foreach GOOS, $(PLATFORMS),\ $(foreach GOOS, $(PLATFORMS),\
$(foreach GOARCH, $(ARCHITECTURES), $(shell [ $(GOOS) = "windows" ] && EXT=".exe"; env GOOS=$(GOOS) GOARCH=$(GOARCH) CGO_ENABLED=0 \ $(foreach GOARCH, $(ARCHITECTURES), $(shell [ $(GOOS) = "windows" ] && EXT=".exe"; env GOOS=$(GOOS) GOARCH=$(GOARCH) CGO_ENABLED=0; \
go build -a -tags netgo -ldflags "-w ${LFLAGS}" -o bin/${NAME}$$EXT; \ go build -a -tags netgo -ldflags "-w ${LFLAGS}" -o bin/${NAME}$$EXT; \
tar -czvf release/${NAME}-$(GOOS)-$(GOARCH).tar.gz -C bin/ ${NAME}$$EXT >/dev/null; \ tar -czvf release/${NAME}-$(GOOS)-$(GOARCH).tar.gz -C bin/ ${NAME}$$EXT >/dev/null; \
sha1sum release/${NAME}-$(GOOS)-$(GOARCH).tar.gz | cut -d " " -f1 > release/${NAME}-$(GOOS)-$(GOARCH).tar.gz.sha1 ))) sha1sum release/${NAME}-$(GOOS)-$(GOARCH).tar.gz | cut -d " " -f1 > release/${NAME}-$(GOOS)-$(GOARCH).tar.gz.sha1 )))
......
#!/bin/bash -e
DIR="$PWD"
VERSION=`./get-version.sh`
echo "Version: $VERSION"
TMP=`mktemp -d`
export GOPATH=$TMP/go
mkdir -p $GOPATH/src/github.com/keycloak
ln -s $DIR $GOPATH/src/github.com/keycloak/keycloak-gatekeeper
cd $GOPATH/src/github.com/keycloak/keycloak-gatekeeper
echo "------------------------------------------------------------------------------------------------------------"
echo "Building:"
echo ""
make release --trace
echo "------------------------------------------------------------------------------------------------------------"
echo "Upload to jboss.org:"
echo ""
rsync -rv --protocol=28 $RELDIR/keycloak-gatekeeper/release/* keycloak@filemgmt.jboss.org:/downloads_htdocs/keycloak/$VERSION/gatekeeper/
echo "------------------------------------------------------------------------------------------------------------"
echo "Done"
echo "------------------------------------------------------------------------------------------------------------"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment