-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
43 lines (37 loc) · 848 Bytes
/
.gitlab-ci.yml
File metadata and controls
43 lines (37 loc) · 848 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
39
40
41
42
43
stages:
- build
- test
- publish
variables:
UV_CACHE_DIR: "$CI_PROJECT_DIR/.uv-cache"
cache:
paths:
- .uv-cache
default:
image: python:3.13
before_script:
- pip install uv
- uv sync --frozen
build-package:
stage: build
script:
- echo "Generating client code from OpenAPI specs..."
- uv run python generate_all.py
- echo "Building distribution artifacts..."
- uv build
artifacts:
paths:
- dist/
expire_in: 1 week
lint:
stage: test
script:
- echo "Running lint checks..."
- uv run ruff check .
# Publish to GitLab Package Registry when a tag is pushed
publish-package:
stage: publish
script:
- uv publish --username gitlab-ci-token --password $CI_JOB_TOKEN --publish-url ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/pypi
rules:
- if: $CI_COMMIT_TAG