Publishing workflow update

Summary:
These changes seem required as per the publishing plugin release notes.

Reference:
https://github.com/vanniktech/gradle-maven-publish-plugin/blob/master/CHANGELOG.md#version-0220-2022-09-09

Reviewed By: aigoncharov

Differential Revision: D40101370

fbshipit-source-id: fdc862de003b72f326c8a9f1b350b7573ba92e29
This commit is contained in:
Lorenzo Blasa
2022-10-05 08:47:29 -07:00
committed by Facebook GitHub Bot
parent 9094609e86
commit 9706f2892d

View File

@@ -25,7 +25,7 @@ jobs:
- name: Write GPG Sec Ring
run: echo '${{ secrets.GPG_KEY_CONTENTS }}' | base64 -d > /tmp/secring.gpg
- name: Update gradle.properties
run: echo -e "signing.secretKeyRingFile=/tmp/secring.gpg\nsigning.keyId=${{ secrets.SIGNING_KEY_ID }}\nsigning.password=${{ secrets.SIGNING_PASSWORD }}\nmavenCentralPassword=${{ secrets.SONATYPE_NEXUS_PASSWORD }}\nmavenCentralUsername=${{ secrets.SONATYPE_NEXUS_USERNAME }}" >> gradle.properties
run: echo -e "signing.secretKeyRingFile=/tmp/secring.gpg\nsigning.keyId=${{ secrets.SIGNING_KEY_ID }}\nsigning.password=${{ secrets.SIGNING_PASSWORD }}\nmavenCentralPassword=${{ secrets.SONATYPE_NEXUS_PASSWORD }}\nmavenCentralUsername=${{ secrets.SONATYPE_NEXUS_USERNAME }}\nSONATYPE_HOST=DEFAULT\nRELEASE_SIGNING_ENABLED=true\nSONATYPE_AUTOMATIC_RELEASE=true" >> gradle.properties
- name: Compute build cache
run: ./scripts/checksum-android.sh checksum-android.txt
- uses: actions/cache@v2
@@ -38,9 +38,7 @@ jobs:
- name: Build artifacts
run: ./gradlew :sample:assembleDebug :sample:assembleRelease && ./gradlew :android:assembleRelease
- name: Upload Archives
run: ./gradlew publish -info --no-parallel --no-daemon
- name: Release and close
run: ./gradlew closeAndReleaseRepository
run: ./gradlew publish -info
- name: Clean secrets
if: always()
run: rm /tmp/secring.gpg