Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
webhooks/gitlab: Use URLOption UI for use_merge_request_title.
Niloth P0e1b8bdf5f26
diff --git a/zerver/lib/integrations.py b/zerver/lib/integrations.pyindex 6a373b9c651..820f27747a3 100644--- a/zerver/lib/integrations.py+++ b/zerver/lib/integrations.py@@ -700,6 +700,11 @@ INCOMING_WEBHOOK_INTEGRATIONS: list[IncomingWebhookIntegration] = [label="Exclude notifications from private projects",input_type="checkbox",),+ WebhookUrlOption(+ name="use_merge_request_title",+ label="Include merge request titles in topics",+ input_type="checkbox_enabled",+ ),],),IncomingWebhookIntegration(diff --git a/zerver/webhooks/gitlab/doc.md b/zerver/webhooks/gitlab/doc.mdindex bfdb6da11f9..a2f6303346a 100644--- a/zerver/webhooks/gitlab/doc.md+++ b/zerver/webhooks/gitlab/doc.md@@ -18,7 +18,9 @@ Receive GitLab notifications in Zulip!1. Decide where to send {{ integration_display_name }} notifications, and[generate the integration URL](/help/generate-integration-url). You'll beable to configure which branches you'll receive notifications from,- and whether to exclude notifications from private projects.+ whether to exclude notifications from private projects, and whether to+ include the merge request title in addition to the merge request ID in+ the topic name.1. Go to your repository on GitLab and click **Settings** on the leftsidebar. Click on **Webhooks** and select **Add new webhook**.@@ -44,13 +46,6 @@ Receive GitLab notifications in Zulip!{!event-filtering-additional-feature.md!}-### Configuration options--* By default, the Zulip topics for merge requests will contain the title- of the GitLab merge request. You can change the topic format to just- contain the merge request ID by adding `&use_merge_request_title=false`- to the generated URL.-### Related documentation{!webhooks-url-specification.md!}