Skip to content

ci: Switch to Trusted Publisher method for PyPI #313

ci: Switch to Trusted Publisher method for PyPI

ci: Switch to Trusted Publisher method for PyPI #313

Workflow file for this run

name: Test-publish package to PyPI
on:
pull_request:
jobs:
test-publish:
runs-on: ubuntu-22.04
environment:
name: testpypi
url: https://test.pypi.org/p/edx-arch-experiments
permissions:
id-token: write # used by pypi-publish
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install pip
run: pip install -r requirements/pip.txt
- name: Build package
run: python setup.py sdist bdist_wheel
- name: Publish to PyPI (test server)
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository_url: https://test.pypi.org/legacy/
skip_existing: true