diff --git a/buildSrc/src/main/groovy/rhino.library-conventions.gradle b/buildSrc/src/main/groovy/rhino.library-conventions.gradle index 3f98be524..d5e0661f8 100644 --- a/buildSrc/src/main/groovy/rhino.library-conventions.gradle +++ b/buildSrc/src/main/groovy/rhino.library-conventions.gradle @@ -79,3 +79,22 @@ task sourceJar(type: Jar) { into 'META-INF' } } + +publishing { + if (project.hasProperty("mavenPassword")) { + repositories { + + maven { + credentials { + username mavenUser + password mavenPassword + } + if (project.version.endsWith('-SNAPSHOT')) { + url mavenSnapshotRepo + } else { + url mavenReleaseRepo + } + } + } + } +}