You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildr.apache.org by do...@apache.org on 2014/08/28 23:17:50 UTC

[3/4] git commit: Only raise exception when staging package rather than every time it is built

Only raise exception when staging package rather than every time it is built


Project: http://git-wip-us.apache.org/repos/asf/buildr/repo
Commit: http://git-wip-us.apache.org/repos/asf/buildr/commit/a2bbb021
Tree: http://git-wip-us.apache.org/repos/asf/buildr/tree/a2bbb021
Diff: http://git-wip-us.apache.org/repos/asf/buildr/diff/a2bbb021

Branch: refs/heads/master
Commit: a2bbb021311e83dc4550e63b60e0b85853c6cc28
Parents: b6a5cfe
Author: Peter Donald <pe...@realityforge.org>
Authored: Fri Aug 29 07:16:59 2014 +1000
Committer: Peter Donald <pe...@realityforge.org>
Committed: Fri Aug 29 07:16:59 2014 +1000

----------------------------------------------------------------------
 Rakefile           | 1 -
 rakelib/stage.rake | 2 ++
 2 files changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/buildr/blob/a2bbb021/Rakefile
----------------------------------------------------------------------
diff --git a/Rakefile b/Rakefile
index 6bc03be..29a43f3 100644
--- a/Rakefile
+++ b/Rakefile
@@ -32,7 +32,6 @@ end
 def spec(platform = RUBY_PLATFORM[/java/] || 'ruby')
   @specs ||= ['ruby', 'java', 'x86-mswin32'].inject({}) { |hash, spec_platform|
     $platform = spec_platform
-    raise 'Gem::Specification.load ignores global context (thus $platform) in later versions' unless RUBY_VERSION == '1.9.3'
     hash.update(spec_platform=>Gem::Specification.load('buildr.gemspec'))
   }
   @specs[platform]

http://git-wip-us.apache.org/repos/asf/buildr/blob/a2bbb021/rakelib/stage.rake
----------------------------------------------------------------------
diff --git a/rakelib/stage.rake b/rakelib/stage.rake
index 5186f1f..ec45075 100644
--- a/rakelib/stage.rake
+++ b/rakelib/stage.rake
@@ -23,6 +23,8 @@ STAGE_DATE = ENV['STAGE_DATE'] ||  Time.now.strftime('%Y-%m-%d')
 task 'prepare' do |task, args|
   gpg_arg = args.gpg || ENV['gpg']
 
+  raise 'Gem::Specification.load ignores global context (thus $platform) in later versions. Please stage project using ruby 1.9.3' unless RUBY_VERSION == '1.9.3'
+
   # Update source files to next release number.
   lambda do
     current_version = spec.version.to_s.split('.').map { |v| v.to_i }.