-
Notifications
You must be signed in to change notification settings - Fork 3
/
.gitlab-ci.yml
54 lines (51 loc) · 808 Bytes
/
.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
# configure
image: python:latest
variables:
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
cache:
paths:
- .cache/pip
- venv/
# common to all scripts
before_script:
- python -V
- pip install -U virtualenv
- virtualenv venv
- source venv/bin/activate
- pip install -U flit
- pip install -U pytest
- pip install -U mypy
- FLIT_ROOT_INSTALL=1 flit install --deps all
# test stage
mypy:
stage: test
script:
- mypy yaqd_control
entry:
stage: test
script:
- yaqd --help
pytest:
stage: test
script:
- pytest
# deploy stage
pages:
stage: deploy
script:
- mkdir public
- cp docs/* public/
artifacts:
paths:
- public/
only:
- main
flit:
stage: deploy
script:
- flit publish
artifacts:
paths:
- dist/*
only:
- tags