@@ -19,48 +19,34 @@ jobs:
19
19
runs-on : ubuntu-latest
20
20
steps :
21
21
# 1. Publish to PyPI
22
- # We still need to use pypa/build because uv does not yet support dynamic version
23
- # see: https://github.com/astral-sh/uv/issues/8714
24
22
- uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
25
- - name : Set up Python 3.10
26
- uses : actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
23
+ - uses : actions/setup-python@a26af69be951a213d495a4c3e4e4022e16d87065 # v5.6.0
27
24
with :
28
25
python-version : " 3.10"
29
- - name : Install pypa/build
30
- run : >-
31
- python -m
32
- pip install
33
- build[uv]
34
- --user
26
+ - name : Install uv
27
+ uses : astral-sh/setup-uv@e92bafb6253dcd438e0484186d7669ea7a8ca1cc # v6.4.3
28
+ with :
29
+ enable-cache : true
30
+ cache-dependency-glob : " uv.lock"
35
31
- name : Build a binary wheel and a source tarball
36
- run : >-
37
- python -m
38
- build
39
- --installer=uv
40
- --sdist
41
- --wheel
42
- --outdir dist/
43
- .
32
+ run : uv build
44
33
- name : Publish distribution 📦 to PyPI
45
34
if : startsWith(github.ref, 'refs/tags')
46
- uses : pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # v1.12.4
47
- with :
48
- user : __token__
49
- password : ${{ secrets.PYPI_API_TOKEN }}
50
- skip-existing : true
35
+ run : uv publish --username __token__ --password ${{ secrets.PYPI_API_TOKEN }}
36
+
51
37
# 2. Publish to GHCR
52
38
- uses : actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
53
39
- name : Extract metadata (tags, labels) for Docker
54
40
id : meta
55
- uses : docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 # v5.7 .0
41
+ uses : docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8 .0
56
42
with :
57
43
images : ghcr.io/${{ github.repository }}
58
44
59
45
- name : Set up Docker Buildx
60
46
uses : docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
61
47
62
48
- name : Login to GitHub Container Registry
63
- uses : docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 # v3.4 .0
49
+ uses : docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5 .0
64
50
with :
65
51
registry : ghcr.io
66
52
# This is the user that triggered the Workflow. In this case, it will
0 commit comments