Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorKamil Trzciński <ayufan@ayufan.eu>2019-06-17 13:38:04 +0300
committerKamil Trzciński <ayufan@ayufan.eu>2019-06-17 13:38:04 +0300
commitbd7febee01232050c93110a1883d40b3a4b31ff7 (patch)
treef58445a0ee3147d2263b99f8f7e186fa82905689 /lib
parentb37ca62686f10dd3c2107ce34c5e1ed800706c67 (diff)
parent396348dd175d70f9cb547f1e037a9b303e1a93aa (diff)
Merge branch 'boolean-values-from-matches-operator' into 'master'
return boolean from Pipeline::Expression::Lexeme::Matches#evaluate See merge request gitlab-org/gitlab-ce!29717
Diffstat (limited to 'lib')
-rw-r--r--lib/gitlab/ci/pipeline/expression/lexeme/matches.rb16
1 files changed, 0 insertions, 16 deletions
diff --git a/lib/gitlab/ci/pipeline/expression/lexeme/matches.rb b/lib/gitlab/ci/pipeline/expression/lexeme/matches.rb
index d7f47c0e7e6..942e4e55323 100644
--- a/lib/gitlab/ci/pipeline/expression/lexeme/matches.rb
+++ b/lib/gitlab/ci/pipeline/expression/lexeme/matches.rb
@@ -13,16 +13,6 @@ module Gitlab
regexp = @right.evaluate(variables)
regexp.scan(text.to_s).any?
-
- if ci_variables_complex_expressions?
- # return offset of first match, or nil if no matches
- if match = regexp.scan(text.to_s).first
- text.to_s.index(match)
- end
- else
- # return true or false
- regexp.scan(text.to_s).any?
- end
end
def self.build(_value, behind, ahead)
@@ -32,12 +22,6 @@ module Gitlab
def self.precedence
10 # See: https://ruby-doc.org/core-2.5.0/doc/syntax/precedence_rdoc.html
end
-
- private
-
- def ci_variables_complex_expressions?
- Feature.enabled?(:ci_variables_complex_expressions)
- end
end
end
end