-
Notifications
You must be signed in to change notification settings - Fork 43
/
.gitlab-ci.yml
104 lines (99 loc) · 1.85 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
101
102
103
104
#TODO test for w64/w32
#TODO test for m64arm
stages:
- build
- test
- deploy
- github
variables:
GIT_DEPTH: 10
workflow:
rules:
- if: '$CI_COMMIT_MESSAGE =~ /^release .*/'
when: never
- when: always
trigger-builds:
stage: build
script: echo trigger build
tags:
- l64
rules:
- if: '$CI_PIPELINE_SOURCE == "push"'
when: manual
build:
stage: build
tags:
- $platform
script:
- VER=$CI_COMMIT_TAG;[ "x$VER" = "x" ] && VER=$CI_COMMIT_BRANCH-$CI_COMMIT_SHA; export VER
- perl -p -i -e 's/EMBEDPYVERSION/`\$\"'${VER}'\"/g' p.q
- make $platform/p.so
artifacts:
expire_in: 2 days
paths:
- p.{k,q}
- $platform/p.so
parallel:
matrix:
- platform: [l64,m64] # TODO win
needs:
- trigger-builds
test-artifacts:
stage: build
tags:
- l64
script: echo package-tests
artifacts:
expire_in: 2 days
paths:
- test.q
- tests/
- ci/makefile
needs:
- trigger-builds
test:
stage: test
tags:
- $platform
variables:
GIT_STRATEGY: none
script: make -f ci/makefile test
dependencies:
- build
- test-artifacts
parallel:
matrix:
- platform: [l64,m64] # TODO m64arm
deploy:
stage: deploy
tags:
- $platform
dependencies:
- build
- test
script: make -f ci/makefile $platform/$target
artifacts:
expire_in: 2 days
paths:
- embedPy_*-$CI_COMMIT_TAG.tgz
rules:
- if: '$CI_COMMIT_TAG == null || $CI_COMMIT_TAG == ""'
when: never
- when: manual
parallel:
matrix:
- platform: l64
target: [docker,github,conda]
- platform: m64
target: [github,conda]
ghrelease:
stage: github
tags:
- l64
script: make -f ci/makefile l64/ghrelease
dependencies:
- deploy
rules:
- if: '$CI_COMMIT_TAG == null || $CI_COMMIT_TAG == ""'
when: never
- when: manual