Rakefile in hookercookerman-amee-0.2.1 vs Rakefile in hookercookerman-amee-0.6.0
- old
+ new
@@ -1,33 +1,50 @@
-%w[rubygems rake rake/clean fileutils newgem rubigen].each { |f| require f }
-require File.dirname(__FILE__) + '/lib/amee'
+require 'rubygems'
+require 'rake'
-# Generate all the Rake tasks
-# Run 'rake -T' to see list of generated tasks (from gem root directory)
-$hoe = Hoe.new('amee', Amee::VERSION) do |p|
- p.developer('Richard Hooker', 'richard.hooker@dynamic50.com')
- p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n")
- p.rubyforge_name = p.name # TODO this is default value
- # p.extra_deps = [
- # ['activesupport','>= 2.0.2'],
- # ]
- p.extra_dev_deps = [
- ['newgem', ">= #{::Newgem::VERSION}"]
- ]
-
- p.clean_globs |= %w[**/.DS_Store tmp *.log]
- path = (p.rubyforge_name == p.name) ? p.rubyforge_name : "\#{p.rubyforge_name}/\#{p.name}"
- p.remote_rdoc_dir = File.join(path.gsub(/^#{p.rubyforge_name}\/?/,''), 'rdoc')
- p.rsync_args = '-av --delete --ignore-errors'
+begin
+ require 'jeweler'
+ Jeweler::Tasks.new do |gem|
+ gem.name = "amee"
+ gem.summary = %Q{Its a gem to interact with the amee api}
+ gem.description = %Q{Amee}
+ gem.email = "hookercookerman@gmail.com"
+ gem.homepage = "http://github.com/hookercookerman/amee"
+ gem.authors = ["Richard Hooker"]
+ gem.test_files.include "features/**/*"
+ gem.files.exclude "spec/**/*"
+ gem.files.exclude "features/**/*"
+ gem.add_development_dependency "rspec", ">=1.2.6"
+ gem.add_development_dependency "cucumber", ">=0.3.94"
+ gem.add_development_dependency "fakeweb", ">=1.2.5"
+
+ gem.add_dependency('httparty', '>=0.4.3')
+ gem.add_dependency('wycats-moneta', '>=0.5.0')
+ gem.add_dependency('crack', '>=0.1.3')
+ gem.add_dependency('validatable', '>=1.6.7')
+ end
+rescue LoadError
+ puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
end
-require 'newgem/tasks' # load /tasks/*.rake
-Dir['tasks/**/*.rake'].each { |t| load t }
-
# TODO - want other tests/tasks run by default? Add them to the list
-# task :default => [:spec, :features]
-require 'cucumber/rake/task'
+task :default => [:spec, :features]
+require 'spec/rake/spectask'
+Spec::Rake::SpecTask.new(:spec) do |spec|
+ spec.libs << 'lib' << 'spec'
+ spec.spec_files = FileList['spec/**/*_spec.rb']
+end
+
+Spec::Rake::SpecTask.new(:rcov) do |spec|
+ spec.libs << 'lib' << 'spec'
+ spec.pattern = 'spec/**/*_spec.rb'
+ spec.rcov = true
+end
+
+task :spec => :check_dependencies
+
+require 'cucumber/rake/task'
namespace :features do
Cucumber::Rake::Task.new(:all) do |t|
t.cucumber_opts = "--format pretty"
end