matrei commented on code in PR #15:
URL: 
https://github.com/apache/grails-gradle-publish/pull/15#discussion_r2430068008


##########
.github/workflows/release.yaml:
##########
@@ -54,59 +45,36 @@ jobs:
           echo "${{ secrets.GRAILS_GPG_KEY }}" | gpg --batch --import
           gpg --list-keys
       - name: "☕️ Setup JDK"
-        uses: actions/setup-java@v4
+        uses: actions/setup-java@v5
         with:
           distribution: liberica
           java-version: 17.0.14 # this must be a specific version for 
reproducible builds
       - name: "🐘 Setup Gradle"
-        uses: gradle/actions/setup-gradle@v4
+        uses: gradle/actions/setup-gradle@v5
         with:
           develocity-access-key: ${{ secrets.GRAILS_DEVELOCITY_ACCESS_KEY }}
-      - name: "📝 Store the target branch"
-        id: extract_branch
-        run: |
-          echo "Determining Target Branch"
-          TARGET_BRANCH=`cat $GITHUB_EVENT_PATH | jq 
'.release.target_commitish' | sed -e 's/^"\(.*\)"$/\1/g'`
-          echo $TARGET_BRANCH
-          echo "value=${TARGET_BRANCH}" >> $GITHUB_OUTPUT
       - name: "📝 Store the current release version"
         id: release_version
-        run: echo "value=${GITHUB_REF:11}" >> $GITHUB_OUTPUT
+        env:
+          TAG_NAME: ${{ github.event.release.tag_name }}
+        run: echo "value=${TAG_NAME#v}" >> $GITHUB_OUTPUT
       - name: "⚙️ Run pre-release"
         uses: apache/grails-github-actions/pre-release@asf
         env:
           RELEASE_VERSION: ${{ steps.release_version.outputs.value }}
-      - name: "📝 Fetch release commit hash"
-        id: commit_hash
-        env:
-          OWNER: ${{ github.repository_owner }}
-          REPO: ${{ steps.extract_repository_name.outputs.repository_name }}
-          TAG: 'v${{ steps.release_version.outputs.value }}'
-          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
-        run: |
-          ref_json=$(gh api "repos/$OWNER/$REPO/git/ref/tags/$TAG")
-          type=$(jq -r '.object.type' <<<"$ref_json")
-          sha=$(jq -r '.object.sha'  <<<"$ref_json")
-          if [ "$type" = "tag" ]; then
-            sha=$(gh api "repos/$OWNER/$REPO/git/tags/$sha" --jq '.object.sha')
-          fi
-          echo "Found Commit Sha: $sha"
-          echo "value=$sha" >>"$GITHUB_OUTPUT"
       - name: "🧩 Run Assemble"
         run: >
           ./gradlew assemble
-          -PgithubBranch=${{ steps.extract_branch.outputs.value }}
       - name: "📦 Generate docs"
         run: >
           ./gradlew grails-publish:groovydoc
-          -PgithubBranch=${{ steps.extract_branch.outputs.value }}
       - name: "✨ Create Staging Repository"
         env:
           NEXUS_PUBLISH_USERNAME: ${{ secrets.NEXUS_STAGE_DEPLOYER_USER }}
           NEXUS_PUBLISH_PASSWORD: ${{ secrets.NEXUS_STAGE_DEPLOYER_PW }}
           NEXUS_PUBLISH_URL: 'https://repository.apache.org/service/local/'

Review Comment:
   Noted, for later!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to