-
Notifications
You must be signed in to change notification settings - Fork 3
32 lines (31 loc) · 884 Bytes
/
publish.yaml
File metadata and controls
32 lines (31 loc) · 884 Bytes
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
name: publish
on: # yamllint disable-line rule:truthy
workflow_dispatch: # remove in favor of release
# release:
# types: [published]
jobs:
pypi:
timeout-minutes: 10
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
environment:
name: pypi
url: https://pypi.org/p/template-python
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: astral-sh/setup-uv@v6
with:
activate-environment: true
- run: uv sync -q --locked --no-default-groups --group stubs
- run: template sys-info --developer
- run: python tools/stubgen.py
- run: uv build
- uses: softprops/action-gh-release@v2
with:
files: dist/*
tag_name: ${{ github.event.release.tag_name }}
- uses: pypa/gh-action-pypi-publish@release/v1