-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
51 lines (46 loc) · 1.25 KB
/
.gitlab-ci.yml
File metadata and controls
51 lines (46 loc) · 1.25 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
include:
- project: "IONDEV/tacklebox"
file: "gitlab_ci_templates/pre-commit.yml"
stages:
- build
variables:
PYTHON_IMAGE: ${CI_REGISTRY}/traque/ont-docker-base/ont-base-python:3.12
pre-commit checks:
extends:
- .tacklebox pre-commit
stage: .pre
rules:
- when: always
test:
stage: .pre
image: ${PYTHON_IMAGE}
tags:
- linux
script:
- pip install -r ./requirements.txt
- pytest ./test/ -s
rules:
- when: always
pages:
stage: build
image: ${CI_REGISTRY}/traque/ont-docker-base/ont-base-python:3.10
needs: []
tags:
- linux
script:
- pip install -r ./requirements.txt
- export ONT_SPECIFICATION_VERSION=$(python find_current_version.py)
- export PYTHONPATH=./docs/mkdocs_extensions/
- mkdocs build --strict --verbose --site-dir public
artifacts:
paths:
- public
variables:
PAGES_PREFIX: ""
pages:
path_prefix: "$PAGES_PREFIX"
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH # Run on default branch (with default PAGES_PREFIX)
- if: $CI_PIPELINE_SOURCE == "merge_request_event" # Conditionally change the prefix for Merge Requests
variables:
PAGES_PREFIX: "mr-$CI_MERGE_REQUEST_SOURCE_BRANCH_NAME" # Prefix with the mr-<name>, like `mr-fix_issue_123`