Permalink
Browse files

Clean and compile as their own rake task

  • Loading branch information...
1 parent 9004f12 commit 8e9899b3cd8dde55b4d0b7ba0fe36af18121f70b @joshuaclayton committed Sep 12, 2010
Showing with 4 additions and 2 deletions.
  1. +4 −2 Rakefile
View
@@ -10,15 +10,17 @@ Rake::ExtensionTask.new("sieve") do |extension|
extension.lib_dir = "lib/sieve"
end
+task :build => [:clean, :compile]
+
require "cucumber/rake/task"
-Cucumber::Rake::Task.new(:cucumber => [:clean, :compile]) do |t|
+Cucumber::Rake::Task.new(:cucumber => :build) do |t|
t.rcov = true
end
task :default => :cucumber
desc "Benchmark C implementation against pure Ruby implementation of the Sieve"
-task(:benchmark => [:clean, :compile]) do
+task(:benchmark => :build) do
def sieve(n)
numbers = (0..n).map {|i| i }
numbers[0] = numbers[1] = nil

0 comments on commit 8e9899b

Please sign in to comment.