-
Notifications
You must be signed in to change notification settings - Fork 0
75 lines (59 loc) · 1.64 KB
/
Copy pathpython-release.yml
File metadata and controls
75 lines (59 loc) · 1.64 KB
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: Python Release
on:
workflow_dispatch:
inputs:
release_tag:
description: Release tag to publish, for example v0.1.0b3
required: false
type: string
push:
tags:
- "v*"
concurrency:
group: python-release-${{ github.ref }}
cancel-in-progress: true
env:
UV_EXTRA_INDEX_URL: https://pypi.nvidia.com
jobs:
build-wheels:
runs-on: ubuntu-24.04
container:
image: quay.io/pypa/manylinux_2_28_x86_64
steps:
- uses: actions/checkout@v4
- name: Install system dependencies
run: ./tools/bootstrap_build_env.sh
- uses: dtolnay/rust-toolchain@stable
- uses: astral-sh/setup-uv@v6
with:
enable-cache: true
- name: Use bundled Python 3.12
run: echo "/opt/python/cp312-cp312/bin" >> "$GITHUB_PATH"
- uses: Swatinem/rust-cache@v2
with:
prefix-key: manylinux-2.28-v1
workspaces: |
backends/cuvs_26_02 -> target
- name: Apply release version from tag
env:
RELEASE_TAG: ${{ inputs.release_tag || github.ref_name }}
run: python tools/apply_release_version.py --tag "$RELEASE_TAG"
- name: Build release wheels
run: just build-wheels
- uses: actions/upload-artifact@v4
with:
name: python-release-dist
path: dist/*
publish:
needs:
- build-wheels
runs-on: ubuntu-24.04
environment: pypi
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v4
with:
name: python-release-dist
path: dist
- uses: pypa/gh-action-pypi-publish@release/v1