Skip to content

Commit

Permalink
Lib Publish config
Browse files Browse the repository at this point in the history
  • Loading branch information
carlospontual committed Mar 18, 2024
1 parent 7e4a2a7 commit afa15e0
Showing 1 changed file with 44 additions and 2 deletions.
46 changes: 44 additions & 2 deletions persistent-cookie-jar-okhttp/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
plugins {
alias(libs.plugins.androidApplication)
alias(libs.plugins.jetbrainsKotlinAndroid)
//id("maven-publish")
`maven-publish`
}

group = "tv.pluto.ads"
version = "1.0.0-alpha01-2024.03.18"

android {
namespace = "com.andreuzaitsev.persistentcookiejar"
compileSdk = 34
Expand All @@ -13,7 +16,6 @@ android {
targetSdk = 33
versionCode = 1
versionName = "1.0"
//consumerProguardFiles("consumer-rules.pro")
}
buildTypes {
release {
Expand All @@ -30,6 +32,46 @@ android {
}
}

afterEvaluate {
publishing {
// These values are provided by the CI environment, args are retrieved from the command line.
val nexusURL: String? by project
val nexusUserName: String? by project
val nexusUserPassword: String? by project
repositories {
maven {
url = uri(nexusURL)
credentials {
username = nexusUserName
password = nexusUserPassword
}
}
}
publications {
publications.withType<MavenPublication> {
// Provide artifacts information requited by Maven Central
pom {
name.set("persistent-cookie-jar-okhttp Library")
description.set(
"Custom version of persistent-cookie-jar-okhttp Library"
)
url.set("https://github.com/Pluto-tv/persistent-cookie-jar-okhttp")

developers {
developer {
id.set("Pluto TV")
name.set("Android Team (MH)")
}
}
scm {
url.set("https://github.com/Pluto-tv/persistent-cookie-jar-okhttp")
}
}
}
}
}
}

dependencies {
implementation(libs.androidx.core.ktx)
implementation(libs.androidx.appcompat)
Expand Down

0 comments on commit afa15e0

Please sign in to comment.