Skip to content
This repository was archived by the owner on Jun 10, 2026. It is now read-only.

Commit 556332e

Browse files
committed
Add TestPyPI publish workflow
1 parent 735d918 commit 556332e

1 file changed

Lines changed: 51 additions & 0 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Publish To TestPyPI
2+
3+
on:
4+
workflow_dispatch:
5+
6+
permissions:
7+
id-token: write
8+
contents: read
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout
16+
uses: actions/checkout@v4
17+
18+
- name: Set up Python
19+
uses: actions/setup-python@v5
20+
with:
21+
python-version: "3.11"
22+
23+
- name: Build package
24+
run: |
25+
python -m pip install --upgrade pip build
26+
python -m build
27+
28+
- name: Upload artifacts
29+
uses: actions/upload-artifact@v4
30+
with:
31+
name: dist-artifacts
32+
path: dist/*
33+
34+
publish:
35+
runs-on: ubuntu-latest
36+
needs: build
37+
environment:
38+
name: testpypi
39+
url: https://test.pypi.org/p/classcharts-api
40+
41+
steps:
42+
- name: Download artifacts
43+
uses: actions/download-artifact@v4
44+
with:
45+
name: dist-artifacts
46+
path: dist
47+
48+
- name: Publish package distributions to TestPyPI
49+
uses: pypa/gh-action-pypi-publish@release/v1
50+
with:
51+
repository-url: https://test.pypi.org/legacy/

0 commit comments

Comments
 (0)