Skip to content

Commit 9073e41

Browse files
Adjustments to upload artifacts to Maven Central
1 parent 77efcfc commit 9073e41

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

Diff for: Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ publish-remote-release:
8787
-PopensslAndroidLibRoot="$(OPENSSL_ANDROID_LIB_ROOT)" \
8888
-PsqlcipherCFlags="$(SQLCIPHER_CFLAGS)" \
8989
-PsqlcipherAndroidClientVersion="$(SQLCIPHER_ANDROID_VERSION)" \
90-
uploadArchives
90+
android-database-sqlcipher:publish
9191

9292
collect-nexus-info := \
9393
read -p "Enter Nexus username:" nexusUsername; \

Diff for: android-database-sqlcipher/maven.gradle

+13-2
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,10 @@ afterEvaluate { project ->
4242
publishing {
4343
publications {
4444
mavenJava(MavenPublication) {
45+
from components.release
4546
groupId = mavenGroup
4647
artifactId = mavenArtifactId
47-
version = mavenPomDescription
48+
version = mavenVersionName
4849
pom {
4950
name = mavenArtifactId
5051
description = mavenPomDescription
@@ -68,10 +69,20 @@ afterEvaluate { project ->
6869
}
6970
}
7071
}
72+
repositories {
73+
maven {
74+
def releasesRepoUrl = getReleaseRepositoryUrl()
75+
url = releasesRepoUrl
76+
credentials {
77+
username = getRepositoryUsername()
78+
password = getRepositoryPassword()
79+
}
80+
}
81+
}
7182
}
7283

7384
signing {
74-
required { isReleaseBuild() }
85+
required { isReleaseBuild() && gradle.taskGraph.hasTask("publish") }
7586
sign configurations.archives
7687
}
7788

0 commit comments

Comments
 (0)