Permalink
Browse files

enforces rake 0.8.0 in the Rakefile

  • Loading branch information...
fxn committed Apr 4, 2013
1 parent b662deb commit 3229a510b3e4ee1285b1db0109d1fe4234abc1fb
Showing with 15 additions and 2 deletions.
  1. +15 −2 Rakefile
View
@@ -1,4 +1,18 @@
require 'rake'
+
+if RAKEVERSION != '0.8.0'
+ puts <<USAGE
+In order to execute tasks please install Ruby 1.8.7 and rake 0.8.0. Then:
+
+ rake _0.8.0_ task_name
+
+Reason is the Jamis template used for the API needs RDoc 1.x. Recent rake libs
+do not provide rake/rdoctask, and RDoc provides 1.x no alternative task. This
+is easy to setup with a Ruby version manager.
+USAGE
+ exit 1
+end
+
require 'rake/rdoctask'
env = %(PKG_BUILD="#{ENV['PKG_BUILD']}") if ENV['PKG_BUILD']
@@ -16,12 +30,11 @@ task :default => :test
desc "Run #{task_name} task for all projects"
task task_name do
PROJECTS.each do |project|
- system %(cd #{project} && #{env} #{$0} #{task_name})
+ system %(cd #{project} && #{env} rake _0.8.0_ #{task_name})
end
end
end
-
desc "Generate documentation for the Rails framework"
Rake::RDocTask.new do |rdoc|
rdoc.rdoc_dir = 'doc/rdoc'

0 comments on commit 3229a51

Please sign in to comment.