From b22287f00fc10800486510c64139b4fefb38ac4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20Trzci=C5=84ski?= Date: Mon, 25 Feb 2019 15:41:52 +0100 Subject: Make CI refs matching to to use UntrustedRegexp This makes ref validation to use always `UntrustedRegexp`. This also splits the existing RubySyntax into separate class. --- doc/ci/yaml/README.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'doc') diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md index aab26092811..251e2cd3d05 100644 --- a/doc/ci/yaml/README.md +++ b/doc/ci/yaml/README.md @@ -255,6 +255,19 @@ job: - branches ``` +Pattern matching is case-sensitive by default. Use `i` flag modifier, like +`/pattern/i` to make a pattern case-insensitive: + +```yaml +job: + # use regexp + only: + - /^issue-.*$/i + # use special keyword + except: + - branches +``` + In this example, `job` will run only for refs that are tagged, or if a build is explicitly requested via an API trigger or a [Pipeline Schedule][schedules]: -- cgit v1.2.1