Skip to content

Commit 5f76e78

Browse files
authored
Use pypi trust provider to upload assets
Use pypi trust provider to upload assets Signed-off-by: Frank Li <Frank.Li@nxp.com>
1 parent 4f4977b commit 5f76e78

1 file changed

Lines changed: 5 additions & 10 deletions

File tree

.github/workflows/build_wrapper.yaml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -177,16 +177,11 @@ jobs:
177177
name: reports
178178
path: ./wrapper/reports/*
179179

180-
- name: Release package to pypi
181-
if: github.ref_type == 'tag'
182-
env:
183-
TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }}
184-
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }}
185-
#TWINE_REPOSITORY_URL: ${{ secrets.TWINE_REPOSITORY_URL }}
186-
working-directory: ./wrapper
187-
run: |
188-
twine --no-color check dist/*
189-
twine --no-color upload --repository pypi dist/*
180+
- name: Publish to PyPI
181+
uses: pypa/gh-action-pypi-publish@release/v1
182+
with:
183+
# This tells the action to use Trusted Publishing with OIDC
184+
skip-existing: true # Optional: don’t fail if the same version is already uploaded
190185

191186
- name: Upload the dist folder
192187
uses: actions/upload-artifact@v4

0 commit comments

Comments
 (0)