-
Notifications
You must be signed in to change notification settings - Fork 0
63 lines (51 loc) · 1.45 KB
/
cd.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
58
59
60
61
62
63
name: CD
on:
push:
tags:
- "v*.*.*"
env:
PYTHON_VERSION: '3.12'
jobs:
release:
runs-on: ubuntu-24.04
defaults:
run:
shell: bash
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v3
- name: Set up Python
run: uv python install ${{ env.PYTHON_VERSION }}
- name: Setup and Activate virtualenv
run: |
uv venv venv --python ${{ env.PYTHON_VERSION }}
source venv/bin/activate
echo "VIRTUAL_ENV=$(pwd)/venv" >> $GITHUB_ENV
echo "$(pwd)/venv/bin" >> $GITHUB_PATH
- name: Install system dependencies
run: sudo apt-get install postgresql-client libpq-dev redis-server
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '18.x'
- name: Install Indico
run: |
uv pip install -U pip setuptools wheel
uv pip install Babel
uv pip install "indico[dev] @ git+https://github.com/indico/indico.git"
- name: Build wheel
run: uv build
- name: Release
uses: softprops/action-gh-release@v2
with:
files: |
dist/*.whl
dist/*.tar.gz
- name: Publish to PyPI
run: uv publish