diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-22 10:31:47 -0800 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2009-11-22 10:31:47 -0800 |
commit | e68bc3f14ea93eabdd4274e66071b65debb5a0a8 (patch) | |
tree | 223c11f38dac1217d8e7e3cd427fdf6018975a9d /ci | |
parent | 3cb46b40a0df1a1f4912625cc2be40b3d630f1f3 (diff) | |
parent | e1935e3c0c35f8f1196239e2b1213c4436049fa5 (diff) | |
download | rails-e68bc3f14ea93eabdd4274e66071b65debb5a0a8.tar.gz rails-e68bc3f14ea93eabdd4274e66071b65debb5a0a8.tar.bz2 rails-e68bc3f14ea93eabdd4274e66071b65debb5a0a8.zip |
Merge commit 'origin/master' into mail
Diffstat (limited to 'ci')
-rwxr-xr-x | ci/ci_build.rb | 64 | ||||
-rw-r--r-- | ci/geminstaller.yml | 25 |
2 files changed, 37 insertions, 52 deletions
diff --git a/ci/ci_build.rb b/ci/ci_build.rb index 0ee952c00b..7ae660fb7d 100755 --- a/ci/ci_build.rb +++ b/ci/ci_build.rb @@ -1,12 +1,18 @@ #!/usr/bin/env ruby require 'fileutils' - include FileUtils -puts "[CruiseControl] Rails build" +def root_dir + @root_dir ||= File.expand_path('../..', __FILE__) +end + +def rake(*tasks) + tasks.each { |task| return false unless system("#{root_dir}/bin/rake", task) } + true +end +puts "[CruiseControl] Rails build" build_results = {} -root_dir = File.expand_path('../..', __FILE__) # Requires gem home and path to be writeable and/or overridden to be ~/.gem, # Will enable when RubyGems supports this properly (in a coming release) @@ -20,44 +26,44 @@ cd root_dir do puts puts "[CruiseControl] Bundling RubyGems" puts - build_results[:bundle] = system 'rm -rf vendor && gem bundle --update' + build_results[:bundle] = system 'rm -rf vendor && env CI=1 gem bundle --update && chmod 755 bin vendor vendor/gems' end cd "#{root_dir}/activesupport" do puts puts "[CruiseControl] Building ActiveSupport" puts - build_results[:activesupport] = system 'rake' - build_results[:activesupport_isolated] = system 'rake test:isolated' + build_results[:activesupport] = rake 'test' + build_results[:activesupport_isolated] = rake 'test:isolated' end -rm_f "#{root_dir}/activerecord/debug.log" -cd "#{root_dir}/activerecord" do +cd "#{root_dir}/railties" do puts - puts "[CruiseControl] Building ActiveRecord with MySQL" + puts "[CruiseControl] Building RailTies" puts - build_results[:activerecord_mysql] = system 'rake mysql:rebuild_databases && rake test_mysql' + build_results[:railties] = rake 'test' end -cd "#{root_dir}/activerecord" do +cd "#{root_dir}/actionpack" do puts - puts "[CruiseControl] Building ActiveRecord with PostgreSQL" + puts "[CruiseControl] Building ActionPack" puts - build_results[:activerecord_postgresql8] = system 'rake postgresql:rebuild_databases && rake test_postgresql' + build_results[:actionpack] = rake 'test' + build_results[:actionpack_isolated] = rake 'test:isolated' end -cd "#{root_dir}/activerecord" do +cd "#{root_dir}/actionmailer" do puts - puts "[CruiseControl] Building ActiveRecord with SQLite 3" + puts "[CruiseControl] Building ActionMailer" puts - build_results[:activerecord_sqlite3] = system 'rake test_sqlite3' + build_results[:actionmailer] = rake 'test' end cd "#{root_dir}/activemodel" do puts puts "[CruiseControl] Building ActiveModel" puts - build_results[:activemodel] = system 'rake' + build_results[:activemodel] = rake 'test' end rm_f "#{root_dir}/activeresource/debug.log" @@ -65,29 +71,29 @@ cd "#{root_dir}/activeresource" do puts puts "[CruiseControl] Building ActiveResource" puts - build_results[:activeresource] = system 'rake' + build_results[:activeresource] = rake 'test' end -cd "#{root_dir}/actionpack" do +rm_f "#{root_dir}/activerecord/debug.log" +cd "#{root_dir}/activerecord" do puts - puts "[CruiseControl] Building ActionPack" + puts "[CruiseControl] Building ActiveRecord with MySQL" puts - build_results[:actionpack] = system 'rake' - build_results[:actionpack_isolated] = system 'rake test:isolated' + build_results[:activerecord_mysql] = rake 'mysql:rebuild_databases', 'test_mysql' end -cd "#{root_dir}/actionmailer" do +cd "#{root_dir}/activerecord" do puts - puts "[CruiseControl] Building ActionMailer" + puts "[CruiseControl] Building ActiveRecord with PostgreSQL" puts - build_results[:actionmailer] = system 'rake' + build_results[:activerecord_postgresql8] = rake 'postgresql:rebuild_databases', 'test_postgresql' end -cd "#{root_dir}/railties" do +cd "#{root_dir}/activerecord" do puts - puts "[CruiseControl] Building RailTies" + puts "[CruiseControl] Building ActiveRecord with SQLite 3" puts - build_results[:railties] = system 'rake' + build_results[:activerecord_sqlite3] = rake 'test_sqlite3' end @@ -100,6 +106,8 @@ puts "[CruiseControl] #{`mysql --version`}" puts "[CruiseControl] #{`pg_config --version`}" puts "[CruiseControl] SQLite3: #{`sqlite3 -version`}" `gem env`.each_line {|line| print "[CruiseControl] #{line}"} +puts "[CruiseControl] Bundled gems:" +`gem bundle --list`.each_line {|line| print "[CruiseControl] #{line}"} puts "[CruiseControl] Local gems:" `gem list`.each_line {|line| print "[CruiseControl] #{line}"} diff --git a/ci/geminstaller.yml b/ci/geminstaller.yml index a38221884b..776ae8d98d 100644 --- a/ci/geminstaller.yml +++ b/ci/geminstaller.yml @@ -1,31 +1,8 @@ --- gems: -- name: erubis - version: >= 2.6.5 - name: geminstaller version: >= 0.4.3 -- name: fcgi - version: >= 0.8.7 -- name: memcache-client - version: >= 1.5.0 -- name: mocha - version: >= 0.9.7 -- name: mysql - #version: >= 2.7 - version: = 2.7 -- name: nokogiri - version: >= 1.3.3 -- name: pg - version: >= 0.8.0 -- name: rack - version: '~> 1.0.0' -- name: rack-test - version: >= 0.5.0 -- name: rake - version: >= 0.8.1 -- name: sqlite3-ruby - version: >= 1.2.2 - name: rubygems-update - version: >= 1.3.3 + version: >= 1.3.5 - name: bundler version: >= 0.6.0 |