-
Notifications
You must be signed in to change notification settings - Fork 603
57 lines (46 loc) · 1.58 KB
/
pre-release.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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: PyPI Pre-Release
on:
schedule:
# weekly on Sunday
- cron: "0 0 * * 0"
# as needed by clicking through the github actions UI
workflow_dispatch:
# we do not want more than one pre-release workflow executing at the same time, ever
concurrency:
group: pre-release
# cancelling in the middle of a release would create incomplete releases
# so cancel-in-progress is false
cancel-in-progress: false
jobs:
pre-release:
if: github.repository_owner == 'ibis-project'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: install python
uses: actions/setup-python@v5
with:
python-version: "3.13"
- name: install uv
uses: astral-sh/[email protected]
- uses: extractions/setup-just@v2
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: compute ibis version
id: get-version
run: echo "value=$(just bump-version)" | tee -a "$GITHUB_OUTPUT"
- name: build wheel and source dist
run: uv build
if: contains(steps.get-version.outputs.value, '.dev')
- name: publish pre-release wheel to test pypi index
if: contains(steps.get-version.outputs.value, '.dev')
run: uv publish --publish-url https://test.pypi.org/legacy/
env:
UV_PUBLISH_TOKEN: ${{ secrets.TEST_PYPI_TOKEN }}
- name: publish pre-release wheel to pypi
if: contains(steps.get-version.outputs.value, '.dev')
run: uv publish
env:
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_TOKEN }}