require "rubygems" require "rake/gempackagetask" PLUGIN = "merb_sequel" NAME = "merb_sequel" VERSION = "0.9.3" AUTHOR = "Wayne E. Seguin, Lance Carlson" EMAIL = "wayneeseguin@gmail.com, lancecarlson@gmail.com" HOMEPAGE = "http://merb-plugins.rubyforge.org/merb_sequel/" SUMMARY = "Merb plugin that provides support for Sequel and Sequel::Model" specification = Gem::Specification.new do |spec| spec.name = NAME spec.email = EMAIL spec.author = AUTHOR spec.version = VERSION spec.summary = SUMMARY spec.platform = Gem::Platform::RUBY spec.has_rdoc = true spec.homepage = HOMEPAGE spec.description = SUMMARY spec.autorequire = PLUGIN spec.require_path = "lib" spec.extra_rdoc_files = ["README", "LICENSE", 'TODO'] # Dependencies #spec.add_dependency("merb", ">= 0.9") spec.add_dependency("merb-core", ">= 0.9.3") # This will probably only be temporary until there is an official merb gem greater than 0.9 spec.add_dependency("sequel", ">= 1.4.0") spec.files = %w(LICENSE README Rakefile TODO) + Dir.glob("{lib,specs,sequel_generators}/**/*") end windows = (PLATFORM =~ /win32|cygwin/) rescue nil SUDO = windows ? "" : "sudo" Rake::GemPackageTask.new(specification) do |package| package.gem_spec = specification end desc "Install merb_sequel" task :install => :package do sh %{#{SUDO} gem install pkg/#{NAME}-#{VERSION} --no-rdoc --no-ri --no-update-sources} end desc 'Release the current version on rubyforge' task :release => :package do sh %{rubyforge add_release merb #{PLUGIN} #{VERSION} pkg/#{NAME}-#{VERSION}.gem} end