-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
executable file
·57 lines (48 loc) · 1.22 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
stages:
- quality
- test
cache:
paths:
- .basher
.job_template: &job_definition
variables:
BASHER_ROOT: $CI_PROJECT_DIR/.basher
before_script:
- apk add --no-cache make git
- git clone --depth=1 https://github.com/basherpm/basher "$BASHER_ROOT" || true
- export PATH="$BASHER_ROOT/bin:$PATH"
- eval "$(basher init -)"
- basher install bats-core/bats-core
- basher install ztombol/bats-assert
- basher install ztombol/bats-support
- basher link "$(pwd)" "shellm/trace"
.quality_template: &quality_definition
<<: *job_definition
image: bash:4.4
stage: quality
style:
<<: *quality_definition
script:
- apk add --no-cache xz
- wget -q -O - https://storage.googleapis.com/shellcheck/shellcheck-stable.linux.x86_64.tar.xz | tar xJ
- mv shellcheck-stable/shellcheck /usr/bin/shellcheck
- rm -rf shellcheck-stable
- make check-style
documentation:
<<: *quality_definition
script:
- make check-documentation
.test_template: &test_definition
<<: *job_definition
stage: test
script:
- make test
bash-4.3:
<<: *test_definition
image: bash:4.3
bash-4.4:
<<: *test_definition
image: bash:4.4
bash-5.0:
<<: *test_definition
image: bash:5.0-beta