-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
65 lines (58 loc) · 1.76 KB
/
.gitlab-ci.yml
File metadata and controls
65 lines (58 loc) · 1.76 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
default:
tags:
- thelab-arm64
stages:
- test
- release
variables:
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
UV_CACHE_DIR: "$CI_PROJECT_DIR/.cache/uv"
UV_VERSION: 0.10.11
BASE_LAYER: trixie-slim
UV_LINK_MODE: copy
PYTHON_VERSION: "3.13"
.rules_mrs_and_protected:
- if: $CI_PIPELINE_SOURCE == "schedule"
when: never
- if: $CI_COMMIT_BRANCH && $CI_COMMIT_REF_PROTECTED == "true"
- if: $CI_COMMIT_TAG && $CI_COMMIT_REF_PROTECTED == "true"
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
.dev_dependency_job: &dev_dependency_job
image: "ghcr.io/astral-sh/uv:${UV_VERSION}-python${PYTHON_VERSION}-${BASE_LAYER}"
cache:
key: devdependencies-${PYTHON_VERSION}
paths:
- .cache/pip/
- .cache/poetry/
- .venv/
include:
- component: gitlab.com/thelabnyc/thelab-ci-components/review@0.8.4
- component: gitlab.com/thelabnyc/thelab-ci-components/precommit@0.8.4
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
when: never
- if: $CI_COMMIT_BRANCH && $CI_COMMIT_REF_PROTECTED == "true"
- if: $CI_COMMIT_TAG && $CI_COMMIT_REF_PROTECTED == "true"
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- component: gitlab.com/thelabnyc/thelab-ci-components/publish-gitlab-release@0.8.4
- component: gitlab.com/thelabnyc/thelab-ci-components/publish-to-pypi@0.8.4
test:lib:
<<: *dev_dependency_job
rules:
- !reference [.rules_mrs_and_protected]
stage: test
needs: []
parallel:
matrix:
- PYTHON_VERSION: "3.13"
TOX_SKIP_ENV: "^(?!py313)"
- PYTHON_VERSION: "3.14"
TOX_SKIP_ENV: "^(?!py314)"
script:
- uvx tox
coverage: '/^TOTAL.+?(\d+\%)$/'
artifacts:
reports:
coverage_report:
coverage_format: cobertura
path: coverage.xml