模板:Gitlab-mention
外观
模板文档
Examples:
{{Gitlab-mention|GitLab username}}→ GitLab username
{{Gitlab-mention|GitLab username|file_regexp=<nowiki>\.(txt|php)$</nowiki>}}→ GitLab username (only commits where at least one of the changed files match /\.(txt|php)$/)
- <translate> Note</translate> <translate> Note:</translate> Don't forget to use <nowiki> tags for the
file_regexpparameter, if you want to have template-specific characters in the regexp, such as|
- <translate> Note</translate> <translate> Note:</translate> Don't forget to use <nowiki> tags for the
{{Gitlab-mention|GitLab username|file_regexp=<nowiki>^includes/.+\.php$</nowiki>|match_all_files}}→ GitLab username (only commits where all of the changed files match /^includes/.+\.php$/)
{{Gitlab-mention|GitLab username|file_regexp=<nowiki>^includes/.+\.php$</nowiki>||only_match_new_files}}→ GitLab username (only commits where at least one of the new files match /^includes/.+\.php$/)
Add this template to [[Git/Reviewers]] to be automatically added as a reviewer on GitLab changes that match certain criteria
| 参数 | 描述 | 类型 | 状态 | |
|---|---|---|---|---|
| GitLab username | 1 | Your username on gitlab.wikimedia.org | 字符串 | 必需 |
| 2 | 2 | If you set this to match_all_files, the file regexp must match all changed files in the commit, not just one of them | 字符串 | 可选 |
| 3 | 3 | Set this to only_match_new_files to make the file regexp only look at new files created by the commit | 未知 | 可选 |
| File path regexp | file_regexp | Only subscribe to commits where at least one of the files matches this regexp. Don't forget to wrap this in <nowiki> tags if you use | or other special characters
| 字符串 | 推荐 |