-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
178 lines (156 loc) · 5.15 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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
# ____ ____ ____ _ _ _ _ _ _____
# | _"\ / ___\/ _ \/ \ / \ / \/ \ / |/__ __\
# /| | | | | \| / \|| | | | | || |\ | | / \
# U| |_| |\ \___ || \_\|| |_/\| |_/\| || | \| | | |
# |____/ u \____/\____\\____/\____/\_/\_/ \_| \_/
# |||_
# (__)_)
#
# Copyright (C) 2019-2020 Aurora Free Open Source Software.
# Copyright (C) 2019-2020 Luís Ferreira <[email protected]>
#
# This file is part of the Aurora Free Open Source Software. This
# organization promote free and open source software that you can
# redistribute and/or modify under the terms of the GNU Lesser General
# Public License Version 3 as published by the Free Software Foundation or
# (at your option) any later version approved by the Aurora Free Open Source
# Software Organization. The license is available in the package root path
# as 'LICENSE' file. Please review the following information to ensure the
# GNU Lesser General Public License version 3 requirements will be met:
# https://www.gnu.org/licenses/lgpl.html .
#
# Alternatively, this file may be used under the terms of the GNU General
# Public License version 3 or later as published by the Free Software
# Foundation. Please review the following information to ensure the GNU
# General Public License requirements will be met:
# http://www.gnu.org/licenses/gpl-3.0.html.
#
# NOTE: All products, services or anything associated to trademarks and
# service marks used or referenced on this file are the property of their
# respective companies/owners or its subsidiaries. Other names and brands
# may be claimed as the property of others.
#
# For more info about intellectual property visit: aurorafoss.org or
# directly send an email to: contact (at) aurorafoss.org .
image: aurorafossorg/archlinux:latest
include:
- project: 'aurorafossorg/core/ci-templates'
ref: master
file: '/common.yml'
- project: 'aurorafossorg/core/ci-templates'
ref: master
file: '/dlang.yml'
# !! project file not working, using remote as workaround !!
stages:
- check
- build
- test
- production
- deploy
editorconfig:
stage: check
image: node:latest
cache:
paths:
- node_modules/
script:
- npm install eclint
- npx eclint check "{,**/}{,meson.build,*.{,json,d,yml,sh,py,ini}}"
allow_failure: true
# Artifacts template
.artifacts_template: &artifacts_definition
artifacts:
name: "$CI_JOB_NAME"
paths:
- .out/bin/
# dub template
.linux-dub_template: &linux-dub_definition
cache:
paths:
- .dub/
image: aurorafossorg/dlang:latest
script:
- dub add-local .
- dub $BUILD_DUB_FLAGS
.x86-linux-deps_template: &x86-linux-deps_definition
before_script:
- pacman -Syu lib32-gcc-libs lib32-glibc --noconfirm --needed
- sudo -u user yay -S lib32-liblphobos --noconfirm
x86_64-linux-dub-dmd-debug:
stage: build
<<: *artifacts_definition
<<: *linux-dub_definition
variables:
BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86_64 --compiler=dmd --build=debug
x86_64-linux-dub-ldc-debug:
<<: *artifacts_definition
<<: *linux-dub_definition
stage: build
variables:
BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86_64 --compiler=ldc --build=debug
x86_64-linux-dub-gdc-debug:
<<: *artifacts_definition
<<: *linux-dub_definition
stage: build
variables:
BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86_64 --compiler=gdc --build=debug
allow_failure: true
# x86-linux-dub-ldc-debug:
# <<: *artifacts_definition
# <<: *linux-dub_definition
# <<: *x86-linux-deps_definition
# stage: build
# variables:
# BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86 --compiler=ldc --build=debug
# x86-linux-dub-dmd-debug:
# stage: build
# <<: *artifacts_definition
# <<: *linux-dub_definition
# <<: *x86-linux-deps_definition
# variables:
# BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86 --compiler=dmd --build=debug
# x86-linux-dub-gdc-debug:
# <<: *artifacts_definition
# <<: *linux-dub_definition
# <<: *x86-linux-deps_definition
# stage: build
# variables:
# BUILD_DUB_FLAGS: $CI_JOB_STAGE --arch=x86 --compiler=gdc --build=debug
# allow_failure: true
unittests:
stage: test
<<: *artifacts_definition
<<: *linux-dub_definition
variables:
BUILD_DUB_FLAGS: $CI_JOB_STAGE --build=unittest
code_coverage:
<<: *linux-dub_definition
stage: test
variables:
BUILD_DUB_FLAGS: $CI_JOB_STAGE --build=unittest-cov --coverage
after_script:
- bash <(curl -s https://codecov.io/bash)
x86_64-linux-dub-ldc-release:
<<: *artifacts_definition
<<: *linux-dub_definition
stage: production
variables:
BUILD_DUB_FLAGS: build --arch=x86_64 --compiler=ldc --build=release
x86_64-linux-dub-dmd-release:
<<: *artifacts_definition
<<: *linux-dub_definition
stage: production
variables:
BUILD_DUB_FLAGS: build --arch=x86_64 --compiler=dmd --build=release
# x86-linux-dub-dmd-release:
# <<: *artifacts_definition
# <<: *linux-dub_definition
# stage: production
# variables:
# BUILD_DUB_FLAGS: build --arch=x86 --compiler=dmd --build=release
# x86-linux-dub-ldc-release:
# <<: *artifacts_definition
# <<: *linux-dub_definition
# stage: production
# variables:
# BUILD_DUB_FLAGS: build --arch=x86 --compiler=ldc --build=release