Created
August 23, 2009 01:52
-
-
Save mcamou/173084 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'rake' | |
require 'rake/clean' | |
require 'rake/rdoctask' | |
require 'rake/testtask' | |
require 'spec/rake/spectask' | |
REQUIRED_GEMS = [ | |
'ci_reporter', | |
'activesupport', | |
'jruby-openssl', | |
'rest-client', | |
'json-jruby' | |
] | |
task :'install-gems' => [] do | |
Gem.manage_gems | |
required_version = Gem::Version::Requirement.new(">= 1.8.0") | |
unless required_version.satisfied_by?(Gem::Version.new(RUBY_VERSION)) | |
puts "Expected Ruby Version #{required_version}, was #{RUBY_VERSION}" | |
exit(1) | |
end | |
Gem::GemRunner.new.run(['install', '--no-ri', '--no-rdoc', '--user-install'] + REQUIRED_GEMS) | |
end | |
Rake::RDocTask.new do |rdoc| | |
#files =['README', 'LICENSE', 'src/main/ruby/lib/**/*.rb'] | |
files =['README'] + Dir.glob('src/main/ruby/{app,conf}/**/*.rb') | |
rdoc.rdoc_files.add(files) | |
rdoc.main = "README" # page to start on | |
rdoc.title = "BlueMountainClient Docs" | |
rdoc.rdoc_dir = 'docs/rdoc' # rdoc output folder | |
rdoc.options << '--line-numbers' | |
end | |
#Rake::TestTask.new do |t| | |
# t.test_files = FileList['src/test/ruby/unit/**/*.rb'] | |
#end | |
Spec::Rake::SpecTask.new do |t| | |
t.libs = ['src/main/ruby/app','src/main/ruby/conf'] | |
t.spec_files = FileList['src/test/ruby/spec/**/*.rb'] | |
t.spec_opts = ['--format', 'specdoc'] | |
t.fail_on_error = true | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment