File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 24
24
25
25
# Follow the Ruby upgrade guide when changing the ruby version
26
26
# link: https://docs.gitlab.com/ee/development/ruby_upgrade.html
27
- current_ruby_version = '3.1.4'
27
+ current_ruby_version = Gitlab :: Util . get_env ( 'RUBY_VERSION' ) || '3.1.4'
28
28
29
29
# NOTE: When this value is updated, flip `USE_NEXT_RUBY_VERSION_IN_*` variable
30
30
# to false to avoid surprises.
31
31
next_ruby_version = Gitlab ::Util . get_env ( 'NEXT_RUBY_VERSION' ) || '3.1.4'
32
32
33
33
# MRs targeting stable branches should use current Ruby version and ignore next
34
- # Ruby version. Also, we provide `USE_OLD_RUBY_VERSION ` variable to force usage
35
- # of current Ruby version.
36
- if Gitlab ::Util . get_env ( 'RUBY2_BUILD' ) == "true" || Gitlab :: Util . get_env ( 'USE_OLD_RUBY_VERSION ') == "true" || Gitlab ::Util . get_env ( 'CI_MERGE_REQUEST_TARGET_BRANCH_NAME' ) &.match? ( /^\d +-\d +-stable$/ )
34
+ # Ruby version. Also, we provide `USE_SPECIFIED_RUBY_VERSION ` variable to force
35
+ # usage of specified Ruby version.
36
+ if Gitlab ::Util . get_env ( 'USE_SPECIFIED_RUBY_VERSION ' ) == "true" || Gitlab ::Util . get_env ( 'CI_MERGE_REQUEST_TARGET_BRANCH_NAME' ) &.match? ( /^\d +-\d +-stable$/ )
37
37
default_version current_ruby_version
38
38
# Regular branch builds are switched to newer Ruby version first. So once the
39
39
# `NEXT_RUBY_VERSION` variable is updated, regular branches (master and feature
You can’t perform that action at this time.
0 commit comments