Author: assaf
Date: Mon Sep 29 17:34:42 2008
New Revision: 700317

URL: http://svn.apache.org/viewvc?rev=700317&view=rev
Log:
Pass gpg_user= in command line when running rake stage.

Modified:
    incubator/buildr/trunk/lib/buildr/core/application.rb
    incubator/buildr/trunk/rakelib/apache.rake

Modified: incubator/buildr/trunk/lib/buildr/core/application.rb
URL: 
http://svn.apache.org/viewvc/incubator/buildr/trunk/lib/buildr/core/application.rb?rev=700317&r1=700316&r2=700317&view=diff
==============================================================================
--- incubator/buildr/trunk/lib/buildr/core/application.rb (original)
+++ incubator/buildr/trunk/lib/buildr/core/application.rb Mon Sep 29 17:34:42 
2008
@@ -486,4 +486,4 @@
       end
     end
   end
-end
+end
\ No newline at end of file

Modified: incubator/buildr/trunk/rakelib/apache.rake
URL: 
http://svn.apache.org/viewvc/incubator/buildr/trunk/rakelib/apache.rake?rev=700317&r1=700316&r2=700317&view=diff
==============================================================================
--- incubator/buildr/trunk/rakelib/apache.rake (original)
+++ incubator/buildr/trunk/rakelib/apache.rake Mon Sep 29 17:34:42 2008
@@ -47,10 +47,9 @@
     fail "#{missing.join(', ')} missing Apache License, please add it before 
making a release!" unless missing.empty?
     puts 'OK'
   end
-
-  task 'check' do
-    ENV['GPG_USER'] or fail 'Please set GPG_USER (--local-user) environment 
variable so we know which key to use.'
-  end
+  
+  # Staging checks specific for Apache.
+  task 'check'=>'license'
 
 
   file 'staged/distro'=>'package' do
@@ -61,8 +60,9 @@
     end
   end
 
-  task 'sign'=>['etc/KEYS', 'staged/distro'] do
-    gpg_user = ENV['GPG_USER'] or fail 'Please set GPG_USER (--local-user) 
environment variable so we know which key to use.'
+  task 'sign'=>['etc/KEYS', 'staged/distro'] do |task, args|
+    gpg_user = args.gpg_user or fail "Please run with gpg_user=<argument for 
gpg --local-user>"
+    puts "Signing packages in staged/distro as user #{gpg_user}"
     FileList['staged/distro/*.{gem,zip,tgz}'].each do |pkg|
       bytes = File.open(pkg, 'rb') { |file| file.read }
       File.open(pkg + '.md5', 'w') { |file| file.write MD5.hexdigest(bytes) << 
' ' << File.basename(pkg) }
@@ -125,7 +125,7 @@
 end
 
 
-task 'stage:check'=>['apache:license', 'apache:check']
+task 'stage:check'=>['apache:check']
 task 'stage:prepare'=>['staged/distro', 'staged/site'] do |task|
   # Since this requires input (passphrase), do it at the very end.
   task.enhance do


Reply via email to