Do not trigger tests if only docs were modified (#9240) (#9257)

This commit is contained in:
Dan Albert
2020-04-02 10:44:51 -06:00
committed by GitHub
parent 90e993fd9a
commit 77b34c278e
3 changed files with 69 additions and 31 deletions

21
ci/maybe-trigger-tests.sh Executable file
View File

@@ -0,0 +1,21 @@
#!/usr/bin/env bash
set -e
cd "$(dirname "$0")/.."
annotate() {
${BUILDKITE:-false} && {
buildkite-agent annotate "$@"
}
}
# Skip if only the docs have been modified
ci/affects-files.sh \
\!^docs/ \
|| {
annotate --style info \
"Skipping all further tests as only docs/ files were modified"
exit 0
}
annotate --style info "Triggering tests"
buildkite-agent pipeline upload ci/buildkite-tests.yml