Skip to content

Publish release

Publish release #1

Workflow file for this run

name: Publish release
on:
release:
types: [published]
jobs:
publish:
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/coh2-live-stats
permissions:
id-token: write
steps:
- uses: actions/checkout@v4
- name: set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: create virtual environment
run: |
python -m venv --without-pip .venv
python -m venv --upgrade-deps --upgrade .venv
- name: activate virtual environment
run: python -c "from scripts.github_actions.activate import run; run()"
- name: install dependencies
run: python -m pip install build twine
- name: build package
run: python -m build
- name: check package
run: python -m twine check dist/*
- name: publish package
uses: pypa/gh-action-pypi-publish@release/v1