Gitlab 推送事件

Gitlab push events

如何设置两个或多个分支来触发钩子? enter image description here

例如: 我有三个分支:master;开发和修复。 我想让这个钩子为 master 和 develop 工作。

在 GitLab 11.3(2018 年 9 月)中引入 "filter push events by branch" 的

gitlab-org/gitlab-foss issue 20338 包括:

support for branch patterns with wildcards (*), like we do with protected branches.

因此模式本身相当有限:

| Wildcard Protected Branch | Matching Branches                                |
|===========================|==================================================|
| *-stable                  | production-stable, staging-stable                |
| production/*              | production/app-server, production/load-balancer  |
| *gitlab*                  | gitlab, gitlab/staging, master/gitlab/production |

没有 xxx|yyy 或语法。

在您的情况下,模式 *e* 足以 select 仅 masterdevelop 而不是 fix.