aboutsummaryrefslogtreecommitdiffstats
path: root/switchtower
diff options
context:
space:
mode:
authorDavid Heinemeier Hansson <david@loudthinking.com>2005-08-24 09:22:20 +0000
committerDavid Heinemeier Hansson <david@loudthinking.com>2005-08-24 09:22:20 +0000
commit6a4d4460ea2569d3bb54e1e75fad945c361cbc9b (patch)
treef5d86ff51511aea73271fad418b3a4efd9164d64 /switchtower
parentc5ff810572c7506b334f70b7036ddc7aee0257fc (diff)
downloadrails-6a4d4460ea2569d3bb54e1e75fad945c361cbc9b.tar.gz
rails-6a4d4460ea2569d3bb54e1e75fad945c361cbc9b.tar.bz2
rails-6a4d4460ea2569d3bb54e1e75fad945c361cbc9b.zip
Made SwitchTower conform to the other Rakefiles in terms of PKG description and beta gems pushing
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2045 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'switchtower')
-rw-r--r--switchtower/Rakefile15
-rw-r--r--switchtower/switchtower.gemspec2
2 files changed, 13 insertions, 4 deletions
diff --git a/switchtower/Rakefile b/switchtower/Rakefile
index 69ac03c9a0..7a4e2c6351 100644
--- a/switchtower/Rakefile
+++ b/switchtower/Rakefile
@@ -2,11 +2,14 @@ require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
require 'rake/gempackagetask'
+require 'rake/contrib/rubyforgepublisher'
require "./lib/switchtower/version"
-SOFTWARE_NAME = "switchtower"
-SOFTWARE_VERSION = SwitchTower::Version::STRING
+PKG_NAME = "switchtower"
+PKG_BUILD = ENV['PKG_BUILD'] ? '.' + ENV['PKG_BUILD'] : ''
+PKG_VERSION = SwitchTower::Version::STRING + PKG_BUILD
+PKG_FILE_NAME = "#{PKG_NAME}-#{PKG_VERSION}"
desc "Default task"
task :default => [ :test ]
@@ -19,7 +22,7 @@ Rake::TestTask.new do |t|
t.verbose = true
end
-GEM_SPEC = eval(File.read("#{File.dirname(__FILE__)}/#{SOFTWARE_NAME}.gemspec"))
+GEM_SPEC = eval(File.read("#{File.dirname(__FILE__)}/#{PKG_NAME}.gemspec"))
Rake::GemPackageTask.new(GEM_SPEC) do |p|
p.gem_spec = GEM_SPEC
@@ -36,3 +39,9 @@ Rake::RDocTask.new do |rdoc|
rdoc.rdoc_files.include 'lib/**/*.rb'
rdoc.template = "jamis"
end
+
+desc "Publish the beta gem"
+task :pgem => [:package] do
+ Rake::SshFilePublisher.new("davidhh@wrath.rubyonrails.org", "public_html/gems/gems", "pkg", "#{PKG_FILE_NAME}.gem").upload
+ `ssh davidhh@wrath.rubyonrails.org './gemupdate.sh'`
+end \ No newline at end of file
diff --git a/switchtower/switchtower.gemspec b/switchtower/switchtower.gemspec
index 1371a67493..679153aeb0 100644
--- a/switchtower/switchtower.gemspec
+++ b/switchtower/switchtower.gemspec
@@ -3,7 +3,7 @@ require './lib/switchtower/version'
Gem::Specification.new do |s|
s.name = 'switchtower'
- s.version = SwitchTower::Version::STRING
+ s.version = PKG_VERSION
s.platform = Gem::Platform::RUBY
s.summary = <<-DESC.strip.gsub(/\n/, " ")
SwitchTower is a framework and utility for executing commands in parallel