Rakefile in tabs_on_rails-1.3.2 vs Rakefile in tabs_on_rails-1.3.3

- old
+ new

@@ -17,24 +17,10 @@ if ENV['SNAPSHOT'].to_i == 1 PKG_VERSION << "." << Time.now.utc.strftime("%Y%m%d%H%M%S") end -# Run all the tests in the /test folder -Rake::TestTask.new do |t| - t.libs << "test" - t.test_files = FileList["test/**/*_test.rb"] - t.verbose = true -end - -# Generate documentation -Rake::RDocTask.new do |rd| - rd.main = "README.rdoc" - rd.rdoc_files.include("*.rdoc", "lib/**/*.rb") - rd.rdoc_dir = "rdoc" -end - # Run test by default. task :default => ["test"] # This builds the actual gem. For details of what all these options # mean, and other ones you can add, check the documentation here: @@ -95,10 +81,26 @@ task :clobber => [:clobber_rdoc, :clobber_rcov, :clobber_package] desc "Package the library and generates the gemspec" task :package => [:gemspec] + +# Run all the tests in the /test folder +Rake::TestTask.new do |t| + t.libs << "test" + t.test_files = FileList["test/**/*_test.rb"] + t.verbose = true +end + +# Generate documentation +Rake::RDocTask.new do |rd| + rd.main = "README.rdoc" + rd.rdoc_files.include("*.rdoc", "lib/**/*.rb") + rd.rdoc_dir = "rdoc" +end + + begin require "rcov/rcovtask" desc "Create a code coverage report" Rcov::RcovTask.new do |t| @@ -109,20 +111,9 @@ rescue LoadError task :clobber_rcov puts "RCov is not available" end -begin - require "code_statistics" - - desc "Show library's code statistics" - task :stats do - CodeStatistics.new(["TabsOnRails", "lib"], - ["Tests", "test"]).to_s - end -rescue LoadError - puts "CodeStatistics (Rails) is not available" -end desc "Publish documentation to the site" task :publish_rdoc => [:clobber_rdoc, :rdoc] do ENV["username"] || raise(ArgumentError, "Missing ssh username") sh "rsync -avz --delete rdoc/ #{ENV["username"]}@code:/var/www/apps/code/#{PKG_NAME}/api"