-
Notifications
You must be signed in to change notification settings - Fork 2
53 lines (43 loc) · 1.23 KB
/
testpypi.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: Publish to TestPyPI using Poetry
# trigger upload on a new push to master
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
environment:
name: testpypi
url: https://test.pypi.org/p/openwfs
# enable openid authentication for PyPi
permissions:
id-token: write # Required for OIDC
steps:
# Checkout the repository
- name: Check out the repository
uses: actions/checkout@v3
# Set up Python
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.9'
# Install Poetry
- name: Install Poetry
uses: abatilo/actions-poetry@v2
with:
version: '1.8.3'
# Install dependencies and build the project
- name: Install dependencies and build package
run: |
poetry install
poetry build
# Publish to TestPyPI
#- name: Publish to TestPyPI
# run: |
# poetry config repositories.testpypi https://test.pypi.org/legacy/
# poetry publish --repository testpypi
- name: Publish package distributions to TestPyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/