diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ceb3e0a..ac888e5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -59,7 +59,7 @@ jobs: if: ${{ success() && github.repository == 'GeyserMC/PackConverter' && github.ref_name == 'master' }} uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 env: - ORG_GRADLE_PROJECT_geysermcUsername: ${{ vars.DEPLOY_USER }} - ORG_GRADLE_PROJECT_geysermcPassword: ${{ secrets.DEPLOY_PASS }} + OPENCOLLAB_USERNAME: ${{ vars.DEPLOY_USER }} + OPENCOLLAB_PASSWORD: ${{ secrets.DEPLOY_PASS }} with: arguments: :converter:publish diff --git a/build.gradle.kts b/build.gradle.kts index aece4aa..2c618e6 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -45,11 +45,12 @@ allprojects { publications.create("library") { artifact(tasks.shadowJar) } + val repoName = if (version.toString().endsWith("SNAPSHOT")) "maven-snapshots" else "maven-releases" repositories { - maven { - val releasesRepoUrl = uri("https://repo.opencollab.dev/maven-releases") - val snapshotsRepoUrl = uri("https://repo.opencollab.dev/maven-snapshots") - url = if (version.toString().endsWith("SNAPSHOT")) snapshotsRepoUrl else releasesRepoUrl + maven("https://repo.opencollab.dev/${repoName}/") { + credentials.username = System.getenv("OPENCOLLAB_USERNAME") + credentials.password = System.getenv("OPENCOLLAB_PASSWORD") + name = "opencollab" } } }