From 7f017c4f669831e97dc9a6ba1313d39693a430ad Mon Sep 17 00:00:00 2001 From: James Daugherty Date: Fri, 13 Dec 2024 11:00:19 -0500 Subject: [PATCH] Cleanup --- .github/workflows/gradle.yml | 10 ++++------ .github/workflows/release.yml | 10 ++++------ build.gradle | 9 +++++---- 3 files changed, 13 insertions(+), 16 deletions(-) diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index 1b4938d00f..236719a726 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -25,9 +25,8 @@ jobs: - name: "🔨 Run Build" id: build env: - GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} - GH_TOKEN: ${{ secrets.GH_TOKEN }} - CHECK_BY_TOKEN: true + SITEMESH_MAVEN_PASSWORD: ${{ secrets.GH_TOKEN }} + CHECK_SITEMESH_REPO: true DEVELOCITY_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} DEVELOCITY_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} DEVELOCITY_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} @@ -56,9 +55,8 @@ jobs: uses: gradle/actions/setup-gradle@v4 - name: "📤 Publish Snapshot to repo.grails.org" env: - GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} - GH_TOKEN: ${{ secrets.GH_TOKEN }} - CHECK_BY_TOKEN: true + SITEMESH_MAVEN_PASSWORD: ${{ secrets.GH_TOKEN }} + CHECK_SITEMESH_REPO: true DEVELOCITY_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} DEVELOCITY_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} DEVELOCITY_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4051999257..924299d908 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -34,9 +34,8 @@ jobs: with: arguments: assemble env: - GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} - GH_TOKEN: ${{ secrets.GH_TOKEN }} - CHECK_BY_TOKEN: true + SITEMESH_MAVEN_PASSWORD: ${{ secrets.GH_TOKEN }} + CHECK_SITEMESH_REPO: true DEVELOCITY_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} DEVELOCITY_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} DEVELOCITY_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} @@ -54,9 +53,8 @@ jobs: id: publish uses: gradle/gradle-build-action@v3 env: - GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} - GH_TOKEN: ${{ secrets.GH_TOKEN }} - CHECK_BY_TOKEN: true + SITEMESH_MAVEN_PASSWORD: ${{ secrets.GH_TOKEN }} + CHECK_SITEMESH_REPO: true DEVELOCITY_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }} DEVELOCITY_BUILD_CACHE_NODE_USER: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_USER }} DEVELOCITY_BUILD_CACHE_NODE_KEY: ${{ secrets.GRADLE_ENTERPRISE_BUILD_CACHE_NODE_KEY }} diff --git a/build.gradle b/build.gradle index 477639c98c..8579b22fd4 100644 --- a/build.gradle +++ b/build.gradle @@ -40,13 +40,14 @@ allprojects { prj -> url = 'https://repository.apache.org/content/repositories/snapshots' } } - println "Check 1:${System.getenv("CHECK_BY_TOKEN")} 2:${prj.name == 'grails-plugin-gsp'?:'skip'} 3:${!sitemeshVersion.endsWith('-SNAPSHOT')}" - if (System.getenv("CHECK_BY_TOKEN") == "true" && prj.name == 'grails-plugin-gsp' && !sitemeshVersion.endsWith('-SNAPSHOT')) { + + if (System.getenv("CHECK_SITEMESH_REPO") && prj.name == 'grails-plugin-gsp' && !sitemeshVersion.endsWith('-SNAPSHOT')) { + System.out.println("Adding Sitemesh Repo") maven { url = 'https://maven.pkg.github.com/codeconsole/grails-plugin-sitemesh3' credentials { - username = System.getenv("GITHUB_ACTOR") - password = System.getenv("GH_TOKEN") + username = 'DOES_NOT_MATTER' + password = System.getenv("SITEMESH_MAVEN_PASSWORD") } } }