adds gopath to jenkinsfile
Some checks failed
gitea-deepak/gogmagog/pipeline/head There was a failure building this commit

This commit is contained in:
2020-12-24 22:12:38 -06:00
parent a4094ba801
commit d3c550e97e

4
Jenkinsfile vendored
View File

@@ -5,6 +5,8 @@ pipeline {
} }
environment { environment {
GO115MODULE = 'on' GO115MODULE = 'on'
GOPATH = "${JENKINS_HOME}/jobs/${JOB_NAME}/builds/${BUILD_ID}"
} }
stages { stages {
stage('Pre Test') { stage('Pre Test') {
@@ -23,10 +25,12 @@ pipeline {
parallel{ parallel{
stage('golint') { stage('golint') {
steps { steps {
withEnv(["PATH+GO=${GOPATH}/bin"]) {
echo 'Running linting' echo 'Running linting'
sh 'golint .' sh 'golint .'
} }
} }
}
stage('go vet') { stage('go vet') {
steps { steps {
echo 'Running vetting' echo 'Running vetting'