44 workflow_dispatch :
55 inputs :
66 version :
7- description : ' Version or semver (e.g., 3.2.0 | patch | minor | major) '
7+ description : ' Choose version bump type '
88 required : true
9- type : string
9+ type : choice
10+ options :
11+ - patch
12+ - minor
13+ - major
14+ default : patch
1015 tag :
1116 description : ' npm dist-tag to publish under'
1217 required : true
1823 create_release :
1924 description : ' Also create a GitHub Release from the tag'
2025 required : false
21- default : false
26+ default : true
2227 type : boolean
23- git_user_name :
24- description : ' Git author name for release commit'
25- required : false
26- default : ' react-native-iap bot'
27- type : string
28- git_user_email :
29- description : ' Git author email for release commit'
30- required : false
31- default : ' github-actions[bot]@users.noreply.github.com'
32- type : string
3328
3429permissions :
3530 contents : write
7671
7772 - name : Configure Git user
7873 run : |
79- git config user.name "${{ github.event.inputs.git_user_name }} "
80- git config user.email "${{ github.event.inputs.git_user_email }} "
74+ git config user.name "react-native-iap bot "
75+ git config user.email "github-actions[bot]@users.noreply.github.com "
8176
8277 - name : Bump version and tag
8378 id : bump
@@ -96,12 +91,15 @@ jobs:
9691 run : |
9792 git push --follow-tags
9893
99- - name : Publish to npm with provenance
94+ - name : Ensure npm CLI v11.5.1 or later (required for OIDC)
95+ run : npm install -g npm@latest
96+
97+ - name : Publish to npm with OIDC trusted publishing
10098 run : |
10199 if [ "${{ github.event.inputs.tag }}" = "latest" ]; then
102- npm publish --provenance -- access public
100+ npm publish --access public --provenance
103101 else
104- npm publish --tag ${{ github.event.inputs.tag }} --provenance -- access public
102+ npm publish --tag ${{ github.event.inputs.tag }} --access public --provenance
105103 fi
106104
107105 - name : Create GitHub Release
0 commit comments