1
0
Fork 0
mirror of https://github.com/jnunemaker/httparty synced 2023-03-27 23:23:07 -04:00

Change Rakefile to Unix format

This commit is contained in:
Sandro Turriate 2009-09-08 21:40:21 -04:00
parent 385dc65ba3
commit 7461fe87b7

View file

@ -1,48 +1,49 @@
ProjectName = 'httparty' ProjectName = 'httparty'
WebsitePath = "jnunemaker@rubyforge.org:/var/www/gforge-projects/#{ProjectName}" WebsitePath = "jnunemaker@rubyforge.org:/var/www/gforge-projects/#{ProjectName}"
require 'rubygems' require 'rubygems'
require 'rake' require 'rake'
require 'echoe' require 'echoe'
require 'spec/rake/spectask' require 'spec/rake/spectask'
require "lib/#{ProjectName}/version" require "lib/#{ProjectName}/version"
require 'cucumber/rake/task' require 'cucumber/rake/task'
Echoe.new(ProjectName, HTTParty::Version) do |p| Echoe.new(ProjectName, HTTParty::Version) do |p|
p.description = "Makes http fun! Also, makes consuming restful web services dead easy." p.description = "Makes http fun! Also, makes consuming restful web services dead easy."
p.install_message = "When you HTTParty, you must party hard!" p.install_message = "When you HTTParty, you must party hard!"
p.url = "http://#{ProjectName}.rubyforge.org" p.url = "http://#{ProjectName}.rubyforge.org"
p.author = "John Nunemaker" p.author = "John Nunemaker"
p.email = "nunemaker@gmail.com" p.email = "nunemaker@gmail.com"
p.extra_deps = [['crack', '>= 0.1.1']] p.extra_deps = [['crack', '>= 0.1.1']]
p.need_tar_gz = false p.need_tar_gz = false
p.docs_host = WebsitePath p.docs_host = WebsitePath
end end
desc 'Upload website files to rubyforge' desc 'Upload website files to rubyforge'
task :website do task :website do
sh %{rsync -av website/ #{WebsitePath}} sh %{rsync -av website/ #{WebsitePath}}
Rake::Task['website_docs'].invoke Rake::Task['website_docs'].invoke
end end
task :website_docs do task :website_docs do
Rake::Task['redocs'].invoke Rake::Task['redocs'].invoke
sh %{rsync -av doc/ #{WebsitePath}/docs} sh %{rsync -av doc/ #{WebsitePath}/docs}
end end
desc 'Preps the gem for a new release' desc 'Preps the gem for a new release'
task :prepare do task :prepare do
%w[manifest build_gemspec].each do |task| %w[manifest build_gemspec].each do |task|
Rake::Task[task].invoke Rake::Task[task].invoke
end end
end end
Rake::Task[:default].prerequisites.clear Rake::Task[:default].prerequisites.clear
task :default => :spec task :default => :spec
Spec::Rake::SpecTask.new do |t| Spec::Rake::SpecTask.new do |t|
t.spec_files = FileList["spec/**/*_spec.rb"] t.spec_files = FileList["spec/**/*_spec.rb"]
end t.spec_opts = ['--options', 'spec/spec.opts']
end
Cucumber::Rake::Task.new(:features) do |t|
t.cucumber_opts = "--format pretty" Cucumber::Rake::Task.new(:features) do |t|
end t.cucumber_opts = "--format pretty"
end