We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0f1221b commit 2ed2a63Copy full SHA for 2ed2a63
lib/cc/engine/standard.rb
@@ -46,7 +46,18 @@ def files_to_inspect
46
end
47
48
def builds_config
49
- @_builds_config ||= ::Standard::BuildsConfig.new.call([])
+ @_builds_config ||= begin
50
+ override_default_ruby_version
51
+ ::Standard::BuildsConfig.new.call([])
52
+ end
53
54
+
55
+ def override_default_ruby_version
56
+ ruby_version = ".ruby-version"
57
+ if File.exist?(ruby_version)
58
+ project_ruby_version = `cat #{ruby_version}`
59
+ ::Standard::LoadsYamlConfig.const_set(:RUBY_VERSION, project_ruby_version)
60
61
62
63
0 commit comments