Skip to content

Commit 49a02c7

Browse files
committed
Factor out common_guard_excludes in CI config
1 parent 2200eec commit 49a02c7

File tree

1 file changed

+28
-26
lines changed

1 file changed

+28
-26
lines changed

ci/ci_common/common.jsonnet

Lines changed: 28 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -10,39 +10,41 @@ common + common.frequencies + {
1010
ci_resources:: (import "ci-resources.libsonnet"),
1111
},
1212

13+
common_guard_excludes:: ["*.md",
14+
"<graal>/*.md",
15+
"<graal>/ci/**.md",
16+
"<graal>/compiler/**.md",
17+
"<graal>/espresso/**.md",
18+
"<graal>/regex/**.md",
19+
"<graal>/sdk/**.md",
20+
"<graal>/substratevm/docs/**", # Substratevm includes substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/image/doc-files/PrintImageHeapConnectedComponents.md in the build
21+
"<graal>/substratevm/CHANGELOG.md",
22+
"<graal>/substratevm/README.md",
23+
"<graal>/sulong/docs/**.md", # Sulong includes its readme in a distribution
24+
"<graal>/sulong/CHANGELOG.md",
25+
"<graal>/tools/**.md",
26+
"<graal>/truffle/**.md",
27+
"<graal>/visualizer/**.md",
28+
"<graal>/vm/src/**.md", # vm/GRAALVM-README.md is included in a distribution
29+
"<graal>/vm/README.md",
30+
"<graal>/vm/benchmarks/**.md",
31+
"<graal>/vm/docs/**",
32+
"<graal>/wasm/**.md",
33+
"<graal>/docs/**",
34+
"<graal>/.devcontainer/**",
35+
"<graal>/.github/**",
36+
"<graal>/vm/ce-release-artifacts.json"
37+
],
38+
1339
# Add a guard to `build` that prevents it from running in the gate
14-
# for a PR that only touches *.md files, the docs, are config files for GitHub
40+
# for a PR that only touches *.md files, the docs, and config files for GitHub
1541
#
1642
# To avoid skipping the deployment of some artifacts, only `gate` jobs and
1743
# post-merges that do not have the `deploy` target are considered.
1844
add_excludes_guard(build):: (
1945
if (std.length(std.find('gate', build.targets)) > 0 || std.length(std.find('deploy', build.targets)) == 0) then {
2046
guard: {
21-
excludes: ["*.md",
22-
"<graal>/*.md",
23-
"<graal>/ci/**.md",
24-
"<graal>/compiler/**.md",
25-
"<graal>/espresso/**.md",
26-
"<graal>/regex/**.md",
27-
"<graal>/sdk/**.md",
28-
"<graal>/substratevm/docs/**", # Substratevm includes substratevm/src/com.oracle.svm.hosted/src/com/oracle/svm/hosted/image/doc-files/PrintImageHeapConnectedComponents.md in the build
29-
"<graal>/substratevm/CHANGELOG.md",
30-
"<graal>/substratevm/README.md",
31-
"<graal>/sulong/docs/**.md", # Sulong includes its readme in a distribution
32-
"<graal>/sulong/CHANGELOG.md",
33-
"<graal>/tools/**.md",
34-
"<graal>/truffle/**.md",
35-
"<graal>/visualizer/**.md",
36-
"<graal>/vm/src/**.md", # vm/GRAALVM-README.md is included in a distribution
37-
"<graal>/vm/README.md",
38-
"<graal>/vm/benchmarks/**.md",
39-
"<graal>/vm/docs/**",
40-
"<graal>/wasm/**.md",
41-
"<graal>/docs/**",
42-
"<graal>/.devcontainer/**",
43-
"<graal>/.github/**",
44-
"<graal>/vm/ce-release-artifacts.json"
45-
]
47+
excludes: self.common_guard_excludes
4648
}
4749
} else {}
4850
) + build,

0 commit comments

Comments
 (0)