@@ -646,16 +646,16 @@ jobs:
646646 - name : Define properties
647647 shell : bash
648648 run : |
649- VERSION="$VERSION"
650649 BRANCH="${GITHUB_REF#refs/heads/}"
651650 COMMIT="${GITHUB_SHA}"
652- RELEASE_NOTES="${{github.server_url}}/${{github.repository}}/releases "
651+ RELEASE_NOTES="$RELEASES_URL "
653652 $RELEASE && RELEASE_NOTES+="/tag/$BRANCH"
654653 echo "NUSPEC_PROPERTIES=version=$VERSION;branch=$BRANCH;commit=$COMMIT;releaseNotes=$RELEASE_NOTES" >> "$GITHUB_ENV"
655654 env :
656655 VERSION : ${{ github.event.inputs.version || '0.0.0.0' }}
657656 RELEASE : ${{ github.event.inputs.release }}
658657 BRANCH : ${{ github.event.inputs.branch }}
658+ RELEASES_URL : ${{ format('{0}/{1}/releases', github.server_url, github.repository) }}
659659 - name : Pack
660660 shell : bash
661661 run : |
@@ -671,9 +671,9 @@ jobs:
671671 path : ' *.nupkg'
672672 - name : Push to nuget.org
673673 if : env.NUGET_API_KEY && startsWith(github.event.inputs.branch, 'chromium/') && github.event.inputs.version && github.event.inputs.nuget == 'true'
674- run : nuget push -Source nuget.org -ApiKey ${{ secrets. NUGET_API_KEY }} *.nupkg
674+ run : nuget push -Source nuget.org -ApiKey "$ NUGET_API_KEY" *.nupkg
675675 env :
676- NUGET_API_KEY : ${{ secrets.NUGET_API_KEY }}
676+ NUGET_API_KEY : ${{ secrets.NUGET_API_KEY }}
677677
678678 conda :
679679 name : Conda packages
@@ -817,7 +817,7 @@ jobs:
817817 continue-on-error : true
818818 run : |
819819 CURRENT_REV=$BRANCH
820- PREVIOUS_REV=$(curl --silent "https://api.github.com/repos/${{ github.repository }}/releases/latest " | jq -r ".tag_name")
820+ PREVIOUS_REV=$(curl --silent "$LATEST_RELEASE_URL " | jq -r ".tag_name")
821821 git clone -b "$BRANCH" https://pdfium.googlesource.com/pdfium.git
822822 cat <<END >> RELEASE.md
823823 ### Changes
@@ -826,6 +826,7 @@ jobs:
826826 git -C "pdfium" log origin/${PREVIOUS_REV}.. --pretty=format:'* [%s](https://pdfium.googlesource.com/pdfium/+/%H)' >> RELEASE.md
827827 env :
828828 BRANCH : ${{ github.event.inputs.branch }}
829+ LATEST_RELEASE_URL : ${{ format('{0}/{1}/releases/latest', github.server_url, github.repository) }}
829830 - name : Generate artifacts checksums
830831 id : hash
831832 run : echo "hashes=$(sha256sum pdfium-*.tgz | base64 -w0)" >> "$GITHUB_OUTPUT"
@@ -835,7 +836,9 @@ jobs:
835836 with :
836837 subject-path : pdfium-*.tgz
837838 - name : Rename provenance file
838- run : mv "${{ steps.provenance.outputs.bundle-path }}" pdfium-attestation.json
839+ run : mv "$BUNDLE_PATH" pdfium-attestation.json
840+ env :
841+ BUNDLE_PATH : ${{ steps.provenance.outputs.bundle-path }}
839842 - name : Publish Release
840843 uses : ncipollo/release-action@v1
841844 with :
0 commit comments