Skip to content

Commit 81d910a

Browse files
committed
Fix merge
1 parent 817c41f commit 81d910a

File tree

2 files changed

+23
-74
lines changed

2 files changed

+23
-74
lines changed

build.gradle

Lines changed: 22 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -5,32 +5,32 @@ buildscript {
55
}
66

77
dependencies {
8-
classpath 'com.android.tools.build:gradle:7.4.2'
8+
classpath 'com.android.tools.build:gradle:8.7.3'
99
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.8.0'
10+
classpath "com.vanniktech:gradle-maven-publish-plugin:0.33.0"
1011
}
1112
}
1213

1314
apply plugin: 'com.android.library'
14-
apply plugin: 'maven-publish'
1515
apply plugin: 'signing'
1616
apply plugin: 'kotlin-android'
17+
apply plugin: 'com.vanniktech.maven.publish'
1718
apply from: 'spec.gradle'
1819
apply from: 'jacoco.gradle'
1920

20-
2121
ext {
2222
splitVersion = '5.3.0'
2323
jacocoVersion = '0.8.8'
2424
}
2525

2626
// Define exclusions for JaCoCo coverage
2727
def coverageExclusions = [
28-
'**/R.class',
29-
'**/R$*.class',
30-
'**/BuildConfig.*',
31-
'**/Manifest*.*',
32-
'**/*Test*.*',
33-
'android/**/*.*'
28+
'**/R.class',
29+
'**/R$*.class',
30+
'**/BuildConfig.*',
31+
'**/Manifest*.*',
32+
'**/*Test*.*',
33+
'android/**/*.*'
3434
]
3535

3636
android {
@@ -76,7 +76,7 @@ android {
7676

7777
testOptions {
7878
unitTests.returnDefaultValues = true
79-
79+
8080
// Configure JaCoCo for all test tasks
8181
unitTests.all {
8282
jacoco {
@@ -114,17 +114,17 @@ android {
114114
}
115115
}
116116

117+
repositories {
118+
google()
119+
mavenCentral()
120+
}
121+
117122
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).configureEach {
118123
kotlinOptions {
119124
jvmTarget = "1.8"
120125
}
121126
}
122127

123-
repositories {
124-
google()
125-
mavenCentral()
126-
}
127-
128128
dependencies {
129129

130130
def roomVersion = '2.4.3'
@@ -195,7 +195,6 @@ dependencies {
195195

196196
def splitPOM = {
197197
name = 'Split Android SDK'
198-
packaging = 'aar'
199198
description = 'Official Split Android SDK'
200199
url = 'https://github.com/splitio/android-client'
201200

@@ -208,15 +207,8 @@ def splitPOM = {
208207

209208
developers {
210209
developer {
211-
id = 'sarrubia'
212-
name = 'Sebastian Arrubia'
213-
email = 'sebastian@split.io'
214-
}
215-
216-
developer {
217-
id = 'fernando'
218-
name = 'Fernando Martin'
219-
email = 'fernando@split.io'
210+
id = 'sdks'
211+
email = 'sdks@split.io'
220212
}
221213
}
222214

@@ -227,59 +219,17 @@ def splitPOM = {
227219
}
228220
}
229221

230-
def releaseRepo = {
231-
name = "ReleaseRepo"
232-
def releasesRepoUrl = "https://oss.sonatype.org/service/local/staging/deploy/maven2/"
233-
def snapshotsRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots/"
234-
url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl
235-
credentials {
236-
username = ossrhUsername
237-
password = ossrhPassword
238-
}
239-
}
240-
241-
afterEvaluate {
242-
android.sourceSets.all { sourceSet ->
243-
if (!sourceSet.name.startsWith("test")) {
244-
sourceSet.kotlin.setSrcDirs([])
245-
}
246-
}
247-
248-
publishing {
249-
publications {
250-
release(MavenPublication) {
251-
from components.release
252-
253-
artifactId = 'android-client'
254-
groupId = 'io.split.client'
255-
version = splitVersion
256-
artifact sourcesJar
257-
artifact javadocJar
258-
259-
pom splitPOM
260-
261-
repositories {
262-
maven releaseRepo
263-
}
264-
}
265-
}
266-
}
267-
268-
task publishRelease(type: PublishToMavenRepository) {
269-
publication = publishing.publications.getByName("release")
270-
repository = publishing.repositories.ReleaseRepo
271-
}
222+
mavenPublishing {
223+
coordinates("io.split.client", "android-client", splitVersion)
224+
pom(splitPOM)
272225

273-
signing {
274-
sign publishing.publications.getByName("release")
275-
}
226+
publishToMavenCentral(false)
227+
signAllPublications()
276228
}
277229

278-
279230
task sourcesJar(type: Jar) {
280231
archiveClassifier.set("sources")
281232
from android.sourceSets.main.java.srcDirs
282-
// archiveClassifier = "sources"
283233
}
284234

285235
task javadoc(type: Javadoc) {
@@ -337,4 +287,3 @@ tasks.withType(Test) {
337287

338288

339289

340-

deps.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,6 @@ releaseRuntimeClasspath - Runtime classpath of compilation 'release' (target (a
123123
| \--- com.google.android.gms:play-services-basement:18.1.0 (*)
124124
\--- androidx.multidex:multidex:2.0.1
125125

126-
(*) - dependencies omitted (listed previously)
126+
(*) - Indicates repeated occurrences of a transitive dependency subtree. Gradle expands transitive dependency subtrees only once per project; repeat occurrences only display the root of the subtree, followed by this annotation.
127127

128128
A web-based, searchable dependency report is available by adding the --scan option.

0 commit comments

Comments
 (0)