-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
100 lines (90 loc) · 1.78 KB
/
.gitlab-ci.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
stages:
- test
- document_test
- deploy
default:
image: python:3.10-slim
before_script:
- apt update
- apt install -y make
- pip install poetry
- poetry config virtualenvs.in-project false
- make dev-install
lint:
stage: test
script:
- make lint
tags:
- no-gpu
pytest:
stage: test
script:
- make test
- poetry run python3 -m coverage html -d coverage
- poetry run python3 -m coverage xml
coverage: '/(?i)total.*? (100(?:\.0+)?\%|[1-9]?\d(?:\.\d+)?\%)$/'
artifacts:
expose_as: coverage
paths:
- coverage/
reports:
coverage_report:
coverage_format: cobertura
path: coverage.xml
tags:
- no-gpu
- GenuineIntel
gpu_test:
image: pytorch/pytorch:2.5.0-cuda12.4-cudnn9-runtime
stage: test
script:
- make gpu_test
tags:
- gpu
e2e_test:
stage: test
script:
- make e2e_test
tags:
- no-gpu
- GenuineIntel
pages_test:
stage: document_test
script:
- make document
tags:
- no-gpu
- GenuineIntel
artifacts:
paths:
- docs/build/html/
pages:
stage: deploy
script:
- mkdir public
- cp -r docs/build/html/* public/
artifacts:
paths:
- public
dependencies:
- pages_test
only:
- main
- develop
- fix_sphinx
.deploy:wheel:
stage: deploy
script:
- poetry version $VERSION
- poetry config repositories.ricos https://pypi.ritc.jp
- poetry build -f wheel
- poetry publish --username ricos --password $RICOS_PYPI_KEY -r ricos --no-ansi -n -v
- poetry publish --username __token__ --password $PYPI_PUBLISH_TOKEN --no-ansi -n -v
deploy:wheel:tags:
image: python:3.11-slim
extends: .deploy:wheel
before_script:
- pip install poetry
- export VERSION=$CI_COMMIT_REF_NAME
only:
- tags