Skip to content

Commit

Permalink
Add Maven-publish plaging config
Browse files Browse the repository at this point in the history
  • Loading branch information
smbduknow committed Feb 12, 2024
1 parent 05b904b commit 5a67bbd
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
1 change: 1 addition & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@ plugins {
alias(libs.plugins.kotlin) apply false
alias(libs.plugins.android.application) apply false
alias(libs.plugins.android.library) apply false
id("com.vanniktech.maven.publish") version "0.25.3" apply false
}
46 changes: 46 additions & 0 deletions perfsuite/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import com.vanniktech.maven.publish.SonatypeHost

plugins {
alias(libs.plugins.kotlin)
alias(libs.plugins.android.library)
id("com.vanniktech.maven.publish")
}

kotlin {
Expand All @@ -26,3 +29,46 @@ dependencies {
implementation(libs.androidx.ktx)
implementation(libs.androidx.fragment)
}

// publishing

val libName = "PerfSuite"
val libDescription = "Lightweight library for collecting app performance metrics"
val libUrl = "https://github.com/bookingcom/perfsuite-android"


val groupId = project.group as String
val artifactId = project.name as String
val version = project.version as String

@Suppress("UnstableApiUsage")
mavenPublishing {
publishToMavenCentral(SonatypeHost.DEFAULT, true)
signAllPublications()

coordinates(groupId, artifactId, version)

pom {
name.set(libName)
description.set(libDescription)
url.set(libUrl)

licenses {
license {
name.set("The Apache License, Version 2.0")
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
}
}
scm {
connection.set("scm:git:github.com/bookingcom/perfsuite-android.git")
developerConnection.set("scm:git:ssh://github.com/bookingcom/perfsuite-android.git")
url.set("https://github.com/bookingcom/perfsuite-android")
}
developers {
developer {
name.set("Vadim Chepovskii")
email.set("[email protected]")
}
}
}
}

0 comments on commit 5a67bbd

Please sign in to comment.