-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcider-ci.yml
159 lines (148 loc) · 4.05 KB
/
cider-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
include: container-build/cider-ci.yml
jobs:
borrow-build-uberjar:
name: Build prod ready uberjar
run_when: &ON_BRANCH_UPDATE
any branch has been updated:
type: branch
include_match: ^.*$
exclude_match: '^.*(no-ci|hotspot).*$'
include: cider-ci/jobs/uberjar.yml
backend-specs:
name: 'Backend: Run specs'
depends_on: &BACKEND_SPEC_DEPS
uberjar was built:
type: job
job_key: borrow-build-uberjar
states: [passed]
run_when: *BACKEND_SPEC_DEPS
context:
include: cider-ci/jobs/backend_specs.yml
check-feature-tasks:
name: Check if feature tasks are up to date
run_when: *ON_BRANCH_UPDATE
context:
include: cider-ci/jobs/feature_tasks_check.yml
feature-specs:
name: Feature specs
depends_on: &FEATURE_SPECS_DEPS
uberjar was built:
type: job
job_key: borrow-build-uberjar
states: [passed]
feature tasks are up to date:
type: job
job_key: check-feature-tasks
states: [passed]
run_when: *FEATURE_SPECS_DEPS
context:
include: cider-ci/jobs/feature_specs.yml
graphql-schema-check:
name: Check GraphQL Schema
depends_on: &UBERJAR
uberjar was built:
type: job
job_key: borrow-build-uberjar
states: [passed]
context:
include: cider-ci/jobs/graph-ql-check.yml
ui-checks:
name: Check UI package
run_when: *ON_BRANCH_UPDATE
tasks:
ui-lint:
git_options:
submodules:
include_match: ^.*$
scripts:
test:
body: |
./ui/bin/lint
lint:
name: "Linting"
description: |
Code checks: static checks and metrics: complexity, duplication, and format,
also other consistency checks.
priority: 3
run_when:
any branch has been updated:
type: branch
include_match: ^.*$
exclude_match: '^.*(no-ci|hotspot).*$'
context:
task_defaults:
git_options:
submodules:
include_match: ^.*$
tasks:
cljc-lint:
scripts:
test:
body: |
#!/usr/bin/env bash
set -euo pipefail
./bin/cljfmt check
all-ok:
name: 'All Tests OK'
depends_on: &ALLOK_DEPS
backend-specs was successful:
type: job
job_key: backend-specs
states: [passed]
feature-specs was successful:
type: job
job_key: feature-specs
states: [passed]
borrow-build-uberjar was successful:
type: job
job_key: borrow-build-uberjar
states: [passed]
ui-checks were successful:
type: job
job_key: ui-checks
states: [passed]
lints were successful:
type: job
job_key: lint
states: [passed]
database merged to master:
job_key: merged-to-master
type: job
submodule: ['database']
states: [passed]
shared-clj merged to master:
job_key: merged-to-master
type: job
submodule: [shared-clj]
states: [passed]
run_when: *ALLOK_DEPS
task: 'echo ALL OK'
good-to-merge:
name: '⚑ Good To Merge'
priority: 99 # no tasks here anyways
description: |
This job depends on all other tests and checks
and it will pass if and only if all dependencies have passed.
Status of this job is **used by github's "branch protection"**!
depends_on: &GOOD_TO_MERGE_DEPENDENCIES
all passed: { type: job, job_key: all-ok, states: [passed] }
run_when: *GOOD_TO_MERGE_DEPENDENCIES
context:
include: cider-ci/jobs/good-to-merge.yml
merged-to-master:
name: "Merged to master"
priority: 999
depends_on:
master branch matches:
type: branch
include_match: ^master$
run_when:
master branch matches:
type: branch
include_match: ^master$
context:
tasks:
merged-to-master:
scripts:
test:
body: "exit 0"