ci_template: job to complain about allow-edit
authorJordan Petridis <jordan@centricular.com>
Fri, 27 Nov 2020 01:05:11 +0000 (03:05 +0200)
committerJordan Petridis <jordan@centricular.com>
Fri, 27 Nov 2020 01:05:11 +0000 (03:05 +0200)
Make sure merge requests have enabled the "allow-edit"
option in the MR so we can rebase them.

Close gstreamer/gstreamer-project#34

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-ci/-/merge_requests/304>

gitlab/ci_template.yml

index e09faa8bbe930a110535d0ec83d1812d61ab599d..1560bf1f2efacea500999526cea53a1e40d80f07 100644 (file)
@@ -403,6 +403,20 @@ check commits:
   script:
     - ci-fairy check-commits --textwidth 0 --no-signed-off-by
 
+#
+# Check "allow-edit" checkbox on merge requests with ci-fairy
+#
+check allow-edit:
+  extends: '.fdo.ci-fairy'
+  needs: []
+  stage: 'preparation'
+  variables:
+    GIT_STRATEGY: 'none'
+  script:
+    - ci-fairy check-merge-request --require-allow-collaboration
+  rules:
+    - if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
+
 #
 # gst-build setup templates
 #