Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 40 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# SPDX-FileCopyrightText: 2024 Ledger SAS
#
# SPDX-License-Identifier: Apache-2.0

name: Upload Python Package

on:
release:
types: [released]

jobs:
deploy:
runs-on: ubuntu-latest
environment: release

permissions:
id-token: write
contents: read

steps:
- uses: actions/checkout@v4

- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: '3.10'

- name: Install twine
run: |
pip install twine

- name: Mint token
id: mint
uses: tschm/token-mint-action@v1.0.3

- name: Publish the package with Twine
run: |
python -m build
twine check dist/*.whl
twine upload --disable-progress-bar -u __token__ -p '${{ steps.mint.outputs.api-token }}' dist