Skip to content

Instantly share code, notes, and snippets.

@marinbek
Created November 28, 2016 15:37
Show Gist options
  • Save marinbek/ebbc24b1896261fd5c4a3505ae4b0eda to your computer and use it in GitHub Desktop.
Save marinbek/ebbc24b1896261fd5c4a3505ae4b0eda to your computer and use it in GitHub Desktop.
jenkins golang setup
export GOROOT=/usr/local/go
export PATH=$GOPATH/bin:$GOROOT/bin:$PATH:$WORKSPACE/bin
export GOPATH=$WORKSPACE
git config url."git@github.com:".insteadOf "https://github.com/"
go get github.com/AlekSi/gocov-xml
go get github.com/axw/gocov/gocov
mkdir -p $GOPATH/src/github.com/NextUserSF/
cd $GOPATH/src/github.com/NextUserSF/
ln -sf $WORKSPACE fetch
cd fetch
glide install -v
go test -check.vv -cover -coverprofile=coverage.out
gocov convert coverage.out | gocov-xml > coverage.xml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment