[polari] ci: Reverse the merge request URL check



commit 14ba0e5c740d2ec2dd650cad475e3643827173f1
Author: Florian Müllner <fmuellner gnome org>
Date:   Fri Aug 27 17:07:32 2021 +0200

    ci: Reverse the merge request URL check
    
    Instead of making sure there is a reference to a bug or merge request,
    make sure there isn't. The reason for this is that marge-bot will always
    append a merge request URL in the end of the commit message.
    
    Part-of: <https://gitlab.gnome.org/GNOME/polari/-/merge_requests/218>

 .gitlab-ci/commit-rules.yml | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/.gitlab-ci/commit-rules.yml b/.gitlab-ci/commit-rules.yml
index 5806ab80..aca46ac3 100644
--- a/.gitlab-ci/commit-rules.yml
+++ b/.gitlab-ci/commit-rules.yml
@@ -1,8 +1,7 @@
 patterns:
-  require:
-    - regex: 
($CI_MERGE_REQUEST_PROJECT_URL/(-/)?(issues|merge_requests)/[0-9]+|https://bugzilla.gnome.org/show_bug.cgi?id=[0-9]+)
-      message: Commit message must contain a link to an issue or merge request
   deny:
+    - regex: '^$CI_MERGE_REQUEST_PROJECT_URL/(-/)?merge_requests/$CI_MERGE_REQUEST_IID$'
+      message: Commit message must not contain a link to its own merge request
     - regex: '^[^:]+: [a-z]'
       message: "Commit message subject should be properly Capitalized. E.g. 'chatView: Marginalize 
extradicity'"
       where: subject


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]