Skip to content

Commit

Permalink
Move to using Ruby 2.0
Browse files Browse the repository at this point in the history
* since the rubygem version is newer, there is a diff on the binstubs
  and the .gemspec files.
* the build_info/*.info files are apparently no longer needed.
* upgraded ruby-debug to work with newer JRuby
  • Loading branch information
ketan committed Oct 25, 2016
1 parent 4aa1c56 commit 099bdca
Show file tree
Hide file tree
Showing 222 changed files with 596 additions and 286 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -129,6 +129,7 @@ server/webapp/WEB-INF/rails.new/log/
server/webapp/WEB-INF/rails.new/logs/
server/webapp/WEB-INF/rails.new/public/assets/
server/webapp/WEB-INF/rails.new/vendor/bundle/jruby/1.9/doc/
server/webapp/WEB-INF/rails.new/vendor/bundle/jruby/1.9/extensions/
target/
test-addon/target/
test-agent/target/
Expand Down
10 changes: 9 additions & 1 deletion server/build.gradle
@@ -1,6 +1,8 @@
import com.thoughtworks.go.build.VerifyJarTask
import groovy.json.JsonOutput
import org.jruby.Ruby
import org.jruby.CompatVersion
import org.jruby.RubyInstanceConfig

/*
* Copyright 2016 ThoughtWorks, Inc.
Expand Down Expand Up @@ -220,7 +222,13 @@ def findGemsToNotPack = {
def gems = []
Ruby ruby
try {
ruby = Ruby.newInstance()
def config = new RubyInstanceConfig()
config.compatVersion = CompatVersion.RUBY2_0
config.output = System.out
config.error = System.err
config.compileMode = RubyInstanceConfig.CompileMode.OFF

ruby = Ruby.newInstance(config)
gems = ruby.evalScriptlet(
"""
Dir.chdir('${project.railsRoot}') do
Expand Down
4 changes: 2 additions & 2 deletions server/webapp/WEB-INF/rails.new/Gemfile
Expand Up @@ -35,6 +35,6 @@ group :development, :test do
gem 'rspec-extra-formatters'

gem 'capybara', '2.2.1'
gem 'ruby-debug-base', '0.10.5.rc10'
gem 'ruby-debug-ide', '0.4.30'
gem 'ruby-debug-base'
gem 'ruby-debug-ide'
end
9 changes: 5 additions & 4 deletions server/webapp/WEB-INF/rails.new/Gemfile.lock
Expand Up @@ -138,8 +138,9 @@ GEM
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
rspec-mocks (~> 2.14.0)
ruby-debug-base (0.10.5.rc10-java)
ruby-debug-ide (0.4.30)
ruby-debug-base (0.10.6-java)
ruby-debug-ide (0.6.0)
rake (>= 0.8.1)
rubyzip (1.2.0)
sass (3.4.22)
sass-rails (5.0.4)
Expand Down Expand Up @@ -207,8 +208,8 @@ DEPENDENCIES
roar
rspec-extra-formatters
rspec-rails (= 2.14.2)
ruby-debug-base (= 0.10.5.rc10)
ruby-debug-ide (= 0.4.30)
ruby-debug-base
ruby-debug-ide
sass-rails
selenium-webdriver
sprockets-rails
Expand Down
2 changes: 1 addition & 1 deletion server/webapp/WEB-INF/rails.new/bin/bundler
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
@@ -1,6 +1,6 @@
#!/bin/sh
'exec' "jruby" '-x' "$0" "$@"
#!/Users/ketanpadegaonkar/projects/gocd/gocd/tools/jruby-1.7.11/bin/jruby
#!/Users/ketanpadegaonkar/projects/gocd/gocd/tools/jruby/bin/jruby
#
# This file was generated by RubyGems.
#
Expand All @@ -15,7 +15,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
@@ -1,6 +1,6 @@
#!/bin/sh
'exec' "jruby" '-x' "$0" "$@"
#!/Users/ketanpadegaonkar/projects/gocd/gocd/tools/jruby-1.7.11/bin/jruby
#!/Users/ketanpadegaonkar/projects/gocd/gocd/tools/jruby/bin/jruby
#
# This file was generated by RubyGems.
#
Expand All @@ -15,7 +15,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down
Expand Up @@ -13,7 +13,7 @@ version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

0 comments on commit 099bdca

Please sign in to comment.