From 72e4781ffcdcce48ba3c22508cdb4317ea1273ae Mon Sep 17 00:00:00 2001 From: Philip Withnall Date: Tue, 17 Nov 2020 14:52:25 +0000 Subject: ci: Temporarily fold SH and Py checks into style-check job MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It doesn’t seem to be possible to use `only:changes` from a branch pipeline extending `.only-default` and have it correctly trigger when `*.sh` or `*.py` files are modified. We possibly need to convert all our pipelines to be merge-request-only, but that’s an avenue I’ve been down before and I couldn’t get it to work. Using [`workflow:rules`](https://docs.gitlab.com/ee/ci/yaml/README.html#workflowrules) might fix that, but I don’t have time to rework the entire CI to use that now. So in the meantime, move the SH and Py checks into the existing style-check job so we’re not always spinning up two additional container instances on every merge request. See !1743. Signed-off-by: Philip Withnall --- .gitlab-ci.yml | 24 ++---------------------- 1 file changed, 2 insertions(+), 22 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 80dbfef83..e79a66767 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -40,36 +40,16 @@ variables: only: - schedules -sh-check: +style-check-diff: extends: .only-default image: $DEBIAN_IMAGE stage: style-check allow_failure: true script: + - .gitlab-ci/run-style-check-diff.sh - .gitlab-ci/run-shellcheck.sh - only: - changes: - - "**/*.sh" - -py-check: - extends: .only-default - image: $DEBIAN_IMAGE - stage: style-check - allow_failure: true - script: - .gitlab-ci/run-black.sh - .gitlab-ci/run-flake8.sh - only: - changes: - - "**/*.py" - -style-check-diff: - extends: .only-default - image: $DEBIAN_IMAGE - stage: style-check - allow_failure: true - script: - - .gitlab-ci/run-style-check-diff.sh check-todos: extends: .only-default -- cgit v1.2.1