Case-insensitivity in regex breaks CI only statement
Summary
Using a /i flag in an only: regex statement breaks regex matching.
Steps to reproduce
- Create a new project with a
gitlab-ci.ymlcontaining the following statements
build:
only:
- /^R\d+S\d+$/
- /BRANCH/
script:
- echo "Hello World"
- Create a new branch called
BRANCH - Verify that the CI job is executing.
- Delete
BRANCHbranch - Amend
gitlab-ci.ymlto the following
only:
- /^R\d+S\d+$/i
- /BRANCH/i
script:
- echo "Hello World"
- Create
BRANCHbranch. - Verify that the CI pipeline was not registered.
Example Project
https://gitlab.com/DylanBartlett/regex-test/
What is the current bug behavior?
Regex statements with the /i flag set do not work at all
What is the expected correct behavior?
Regex statement should match and become case insensitive.
Output of checks
This bug happens on GitLab.com
Edited by Dylan Bartlett