Skip to content

Commit

Permalink
Minor publishing changes
Browse files Browse the repository at this point in the history
  • Loading branch information
vpriscan committed Jun 28, 2019
1 parent e4370d1 commit c6c1133
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 7 deletions.
23 changes: 19 additions & 4 deletions build.gradle.kts
Expand Up @@ -94,6 +94,9 @@ publishing {
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
scm {
url.set("https://github.com/ReactiveX/RxKotlin.git")
}
}

publications {
Expand All @@ -102,8 +105,6 @@ publishing {
version = "${project.version}-SNAPSHOT"

from(components["java"])
artifact(sourcesJar)
artifact(javadocJar)

pom.initPom()
}
Expand All @@ -121,8 +122,8 @@ publishing {
}

bintray {
user = project.findProperty("bintray.user") as? String
key = project.findProperty("bintray.key") as? String
user = project.findProperty("bintrayUser") as? String
key = project.findProperty("bintrayKey") as? String

val isRelease = project.findProperty("release") == "true"

Expand All @@ -138,11 +139,25 @@ bintray {
repo = "RxJava"
name = "RxKotlin"
setLicenses("Apache-2.0")
setLabels("reactivex", "rxjava", "rxkotlin")
websiteUrl = "https://github.com/ReactiveX/RxKotlin"
issueTrackerUrl = "https://github.com/ReactiveX/RxKotlin/issues"
vcsUrl = "https://github.com/ReactiveX/RxKotlin.git"

with(version) {
name = project.version.toString()
vcsTag = project.version.toString()

with(gpg){
sign = true
}

with(mavenCentralSync) {
sync = true
user = project.findProperty("sonatypeUsername") as? String
password = project.findProperty("sonatypePassword") as? String
close = "1"
}
}
}
}
6 changes: 3 additions & 3 deletions gradle/buildViaTravis.sh
Expand Up @@ -6,11 +6,11 @@ if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then
./gradlew build
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" == "" ]; then
echo -e 'Build Branch with Snapshot => Branch ['$TRAVIS_BRANCH']'
./gradlew -Prelease.travisci=true -Pbintray.user="${bintrayUser}" -Pbintray.key="${bintrayKey}" -PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
build bintrayUpload --stacktrace
./gradlew build
echo -e 'To publish snapshot version to your local maven repo, execute: ./gradlew clean build publishSnapshotPublicationToMavenLocal'
elif [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$TRAVIS_TAG" != "" ]; then
echo -e 'Build Branch for Release => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG']'
./gradlew -Prelease.travisci=true -Pbintray.user="${bintrayUser}" -Pbintray.key="${bintrayKey}" -PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
./gradlew -Prelease.travisci=true -PbintrayUser="${bintrayUser}" -PbintrayKey="${bintrayKey}" -PsonatypeUsername="${sonatypeUsername}" -PsonatypePassword="${sonatypePassword}" \
-Prelease=true build bintrayUpload --stacktrace
else
echo -e 'WARN: Should not be here => Branch ['$TRAVIS_BRANCH'] Tag ['$TRAVIS_TAG'] Pull Request ['$TRAVIS_PULL_REQUEST']'
Expand Down

0 comments on commit c6c1133

Please sign in to comment.