CI: bring back mr-settings check (MR 2234)

Add the check again that ensures we can write to the target repository.
This is needed for our merge style, we add the MR-ID to the title of the
commit message, and may do small fixups while merging.
This commit is contained in:
Oliver Smith 2024-01-18 23:02:31 +00:00
parent 3e3c639d05
commit f8d203e8e5
No known key found for this signature in database
GPG Key ID: 5AE7F5513E0885CB
1 changed files with 19 additions and 0 deletions

View File

@ -1,5 +1,14 @@
image: alpine:edge
# The mr-settings check needs to run in a MR specific context. With this block,
# the whole pipeline runs in that context for MRs. Otherwise we would have two
# pipelines for MRs.
workflow:
rules:
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
- if: $CI_COMMIT_BRANCH == 'master'
- if: $CI_COMMIT_BRANCH == 'wip'
before_script:
- ".ci/note.sh"
- "echo 'https://dl-cdn.alpinelinux.org/alpine/edge/testing' >> /etc/apk/repositories"
@ -37,3 +46,13 @@ vermin:
stage: lint
script:
- ".ci/vermin.sh"
mr-settings:
stage: lint
rules:
- if: $CI_PIPELINE_SOURCE == 'merge_request_event'
before_script:
- "apk -q add python3"
- "wget -q 'https://gitlab.com/postmarketOS/ci-common/-/raw/master/check_mr_settings.py'"
script:
- "python3 ./check_mr_settings.py"