-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (35 loc) · 910 Bytes
/
push.yml
File metadata and controls
38 lines (35 loc) · 910 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
33
34
35
36
37
38
name: push
on:
push:
branches:
- master
jobs:
tag:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: butlerlogic/action-autotag@1.1.2 # https://github.com/ButlerLogic/action-autotag/issues/45#issuecomment-1825726927
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
with:
strategy: regex
root: pyproject.toml
regex_pattern: 'current_version = "(?<version>\d+\.\d+\.\d+)"'
publish:
runs-on: ubuntu-latest
needs:
- tag
environment:
name: pypi
permissions:
id-token: write
steps:
- uses: actions/checkout@v4
- uses: astral-sh/setup-uv@v5
with:
enable-cache: true
- uses: actions/setup-python@v5
with:
python-version-file: pyproject.toml
- run: uv build
- run: uv publish --trusted-publishing always