Skip to content

Commit 4ec1323

Browse files
DEVO-710: Publishing java client api builds to nexus
1 parent b8fad1f commit 4ec1323

File tree

2 files changed

+29
-1
lines changed

2 files changed

+29
-1
lines changed

Jenkinsfile

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,24 @@ pipeline{
176176
junit '**/build/**/TEST*.xml'
177177
}
178178
}
179-
179+
stage('publish'){
180+
when {
181+
branch 'develop'
182+
not {
183+
expression {return params.regressions}
184+
}
185+
}
186+
steps{
187+
sh label:'publish', script: '''#!/bin/bash
188+
export JAVA_HOME=$JAVA_HOME_DIR
189+
export GRADLE_USER_HOME=$WORKSPACE/$GRADLE_DIR
190+
export PATH=$GRADLE_USER_HOME:$JAVA_HOME/bin:$PATH
191+
cp ~/.gradle/gradle.properties $GRADLE_USER_HOME;
192+
cd java-client-api
193+
./gradlew publish
194+
'''
195+
}
196+
}
180197
stage('regressions-11.0-Latest') {
181198
when {
182199
allOf {

ml-development-tools/build.gradle

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,17 @@ publishing {
5555
from components.java
5656
}
5757
}
58+
repositories {
59+
maven {
60+
if(project.hasProperty("mavenUser")) {
61+
credentials {
62+
username mavenUser
63+
password mavenPassword
64+
}
65+
}
66+
url publishUrl
67+
}
68+
}
5869
}
5970

6071
compileKotlin {

0 commit comments

Comments
 (0)