Add ability to publish to 2009scape maven repo

This commit is contained in:
ceikry 2022-07-02 13:42:27 -05:00
parent 67379a8c8b
commit ca42aa9c82
3 changed files with 49 additions and 2 deletions

38
.gitlab-ci.yml Normal file
View file

@ -0,0 +1,38 @@
# To contribute improvements to CI/CD templates, please follow the Development guide at:
# https://docs.gitlab.com/ee/development/cicd/templates.html
# This specific template is located at:
# https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Gradle.gitlab-ci.yml
# This is the Gradle build system for JVM applications
# https://gradle.org/
# https://github.com/gradle/gradle
image: gradle:alpine
# Disable the Gradle daemon for Continuous Integration servers as correctness
# is usually a priority over speed in CI environments. Using a fresh
# runtime for each build is more reliable since the runtime is completely
# isolated from any previous builds.
variables:
GRADLE_OPTS: "-Dorg.gradle.daemon=false"
before_script:
- GRADLE_USER_HOME="$(pwd)/.gradle"
- export GRADLE_USER_HOME
build:
stage: build
script: gradle --build-cache assemble
cache:
key: "$CI_COMMIT_REF_NAME"
policy: push
paths:
- build
- .gradle
deploy:
image: gradle:6.5-jdk11
script:
- 'gradle publish'
only:
- main

View file

@ -7,10 +7,19 @@ version '1.4'
repositories {
mavenCentral()
maven {
url "https://gitlab.com/api/v4/groups/10870176/-/packages/maven"
name "GitLab"
credentials(HttpHeaderCredentials) {
name = 'Job-Token'
value = System.getenv("CI_JOB_TOKEN")
}
authentication {
header(HttpHeaderAuthentication)
}
}
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib"
}

0
gradlew vendored Normal file → Executable file
View file