diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 80f557b..22746ef 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -39,6 +39,7 @@ jobs: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID }} + SONATYPE_DESCRIPTION: Created by GitHub Actions - name: Publish artifacts to Sonatype id: publish @@ -60,6 +61,7 @@ jobs: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} SONATYPE_REPOSITORY_ID: ${{ steps.create-nexus-staging.outputs.repository_id }} + SONATYPE_DESCRIPTION: Closed by GitHub Actions - name: Extract version from build.gradle.kts id: extract_version diff --git a/scripts/create-nexus-staging-repo.sh b/scripts/create-nexus-staging-repo.sh index 882516e..11739e7 100755 --- a/scripts/create-nexus-staging-repo.sh +++ b/scripts/create-nexus-staging-repo.sh @@ -4,7 +4,8 @@ jsonOutput=$( curl -s --request POST -u "$SONATYPE_USERNAME:$SONATYPE_PASSWORD" \ --url https://s01.oss.sonatype.org/service/local/staging/profiles/"${SONATYPE_STAGING_PROFILE_ID}"/start \ --header 'Accept: application/json' \ - --header 'Content-Type: application/json' + --header 'Content-Type: application/json' \ + --data '{ "data": {"description" : "'"$SONATYPE_DESCRIPTION"'"} }' ) stagingRepositoryId=$(echo "$jsonOutput" | jq -r '.data.stagedRepositoryId') diff --git a/scripts/release-nexus-staging.sh b/scripts/release-nexus-staging.sh index ceab779..770d46a 100755 --- a/scripts/release-nexus-staging.sh +++ b/scripts/release-nexus-staging.sh @@ -5,7 +5,7 @@ closingRepository=$( --url https://s01.oss.sonatype.org/service/local/staging/bulk/close \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ - --data '{ "data" : {"stagedRepositoryIds":["'"$SONATYPE_REPOSITORY_ID"'"] } }' + --data '{ "data" : {"stagedRepositoryIds":["'"$SONATYPE_REPOSITORY_ID"'"], "description":"'"$SONATYPE_DESCRIPTION"'" } }' ) if [ ! -z "$closingRepository" ]; then