Shreyash Kore
10/25/2024, 9:05 AMmbonnin
10/25/2024, 9:22 AMShreyash Kore
10/25/2024, 9:24 AMmbonnin
10/25/2024, 9:25 AMmbonnin
10/25/2024, 9:26 AMmbonnin
10/25/2024, 9:26 AMmbonnin
10/25/2024, 9:27 AMTgo1014
10/25/2024, 9:28 AMmbonnin
10/25/2024, 9:29 AMShreyash Kore
10/25/2024, 9:29 AMShreyash Kore
10/25/2024, 9:29 AMmbonnin
10/25/2024, 9:31 AMFor my hobby library, I think this would be overkillIt's not that hard really
mbonnin
10/25/2024, 9:31 AMShreyash Kore
10/25/2024, 10:17 AMPublishing.kt
. Seems like there's lot for me to learn there 🙂. One last question from my side... How these SNAPSHOTs will be consumed? Which repository do need to declare? Any other setup needed?mbonnin
10/25/2024, 10:19 AMPublishing.kt
, there's way too much stuff in there 😅mbonnin
10/25/2024, 10:20 AMShreyash Kore
10/25/2024, 10:37 AMeygraber
10/27/2024, 2:07 AMCLOVIS
10/30/2024, 7:45 PM// When running in GitLab CI, uses the auto-created CI variables to configure the GitLab Maven Registry.
// For more information on the variables and their values, see:
// - <https://docs.gitlab.com/ee/user/packages/maven_repository/>
// - <https://docs.gitlab.com/ee/ci/variables/predefined_variables.html>
publishing {
repositories {
val projectId = System.getenv("CI_PROJECT_ID") ?: return@repositories
val token = System.getenv("CI_JOB_TOKEN") ?: return@repositories
val api = System.getenv("CI_API_V4_URL") ?: return@repositories
maven {
name = "GitLab"
url = uri("$api/projects/$projectId/packages/maven")
credentials(HttpHeaderCredentials::class.java) {
name = "Job-Token"
value = token
}
authentication {
create<HttpHeaderAuthentication>("header")
}
}
}
}
CLOVIS
10/30/2024, 7:46 PMeygraber
10/30/2024, 7:53 PM-SNAPSHOT
to the version. I don't have to remember the repo url, add it to the project, etc...CLOVIS
10/30/2024, 7:54 PMmavenCentral()
eygraber
10/30/2024, 7:54 PMeygraber
10/30/2024, 7:55 PMs01
but it's constant.