-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (38 loc) · 1.09 KB
/
publish-to-pypi.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
name: Build and upload to pypi
on:
release:
types:
- created
jobs:
build:
runs-on: ubuntu-latest
permissions:
# This permission is required for trusted publishing.
id-token: write
contents: read
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up python
id: setup-python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true
- name: Install dependencies
run: poetry install --no-interaction --no-root --with=dev,ci
- name: Check Schema Hash with upstream
run: |
source .venv/bin/activate
python scripts/checkUpstreamSchema.py
- name: Mint token
id: mint
uses: tschm/[email protected]
- name: Publish to PyPI
run: |
poetry publish --build -u __token__ -p '${{ steps.mint.outputs.api-token }}'