Skip to content

Commit

Permalink
Merge pull request #1 from KwakEuiJin/feature/maven-publish
Browse files Browse the repository at this point in the history
Maven publish 로직 추가
  • Loading branch information
kez-lab authored Aug 16, 2024
2 parents 4122ec1 + 1d5caee commit ac7f63e
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 10 deletions.
20 changes: 11 additions & 9 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ composeBom = "2024.06.00"
appcompat = "1.7.0"
material = "1.12.0"
kotlinx-datetime = "0.6.0"
vankiktechMaven = "0.28.0"
compose-android = "1.6.8"
material3 = "1.2.1"

[libraries]
androidx-core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "coreKtx" }
Expand All @@ -20,21 +23,20 @@ androidx-espresso-core = { group = "androidx.test.espresso", name = "espresso-co
androidx-lifecycle-runtime-ktx = { group = "androidx.lifecycle", name = "lifecycle-runtime-ktx", version.ref = "lifecycleRuntimeKtx" }
androidx-activity-compose = { group = "androidx.activity", name = "activity-compose", version.ref = "activityCompose" }
androidx-compose-bom = { group = "androidx.compose", name = "compose-bom", version.ref = "composeBom" }
androidx-ui = { group = "androidx.compose.ui", name = "ui" }
androidx-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics" }
androidx-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling" }
androidx-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview" }
androidx-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest" }
androidx-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4" }
androidx-material3 = { group = "androidx.compose.material3", name = "material3" }
androidx-appcompat = { group = "androidx.appcompat", name = "appcompat", version.ref = "appcompat" }
material = { group = "com.google.android.material", name = "material", version.ref = "material" }
androidx-ui = { group = "androidx.compose.ui", name = "ui", version.ref = "compose-android" }
androidx-ui-graphics = { group = "androidx.compose.ui", name = "ui-graphics", version.ref = "compose-android" }
androidx-ui-tooling = { group = "androidx.compose.ui", name = "ui-tooling", version.ref = "compose-android" }
androidx-ui-tooling-preview = { group = "androidx.compose.ui", name = "ui-tooling-preview", version.ref = "compose-android" }
androidx-ui-test-manifest = { group = "androidx.compose.ui", name = "ui-test-manifest", version.ref = "compose-android" }
androidx-ui-test-junit4 = { group = "androidx.compose.ui", name = "ui-test-junit4", version.ref = "compose-android" }
androidx-material3 = { group = "androidx.compose.material3", name = "material3", version.ref = "material3"}
kotlinx-datetime = { module = "org.jetbrains.kotlinx:kotlinx-datetime", version.ref = "kotlinx-datetime" }

[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
jetbrains-kotlin-android = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
android-library = { id = "com.android.library", version.ref = "agp" }
compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
vanniktech-maven = { id = "com.vanniktech.maven.publish", version.ref = "vankiktechMaven" }


42 changes: 41 additions & 1 deletion picker/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
import com.vanniktech.maven.publish.SonatypeHost

plugins {
alias(libs.plugins.android.library)
alias(libs.plugins.jetbrains.kotlin.android)
alias(libs.plugins.compose.compiler)
alias(libs.plugins.vanniktech.maven)
}

group = "io.github.KwaEuiJin"
version = "0.0.1"

android {
namespace = "com.kez.picker"
compileSdk = 34
Expand Down Expand Up @@ -41,7 +47,6 @@ dependencies {
implementation(libs.androidx.core.ktx)
implementation(libs.androidx.lifecycle.runtime.ktx)
implementation(libs.androidx.activity.compose)
implementation(platform(libs.androidx.compose.bom))
implementation(libs.androidx.ui)
implementation(libs.androidx.ui.graphics)
implementation(libs.androidx.ui.tooling.preview)
Expand All @@ -51,4 +56,39 @@ dependencies {
androidTestImplementation(libs.androidx.espresso.core)

implementation(libs.kotlinx.datetime)
}

mavenPublishing {
publishToMavenCentral(SonatypeHost.CENTRAL_PORTAL)

signAllPublications()

coordinates("io.github.KwakEuiJin", "compose-datepicker", "0.0.1")

pom {
name = "Compose-DatePicker"
description = "Compose DatePicker"
url = "https://github.com/KwakEuiJin/Compose-DatePicker"
inceptionYear = "2024"

licenses {
license {
name = "The Apache License, Version 2.0"
url = "http://www.apache.org/licenses/LICENSE-2.0.txt"
}
}
developers {
developer {
id = "KwakEuiJin"
name = "KEZ"
url = "https://github.com/KwakEuiJin"
}
}

scm {
url.set("https://github.com/KwakEuiJin/Compose-DatePicker")
connection.set("scm:git:git://github.com/KwakEuiJin/Compose-DatePicker.git")
developerConnection.set("scm:git:ssh://[email protected]/KwakEuiJin/Compose-DatePicker.git")
}
}
}
1 change: 1 addition & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
pluginManagement {
repositories {
google()
google {
content {
includeGroupByRegex("com\\.android.*")
Expand Down

0 comments on commit ac7f63e

Please sign in to comment.