Rakefile in net-irc-0.0.8 vs Rakefile in net-irc-0.0.9

- old
+ new

@@ -3,11 +3,10 @@ require 'rake' require 'rake/clean' require 'rake/packagetask' require 'rake/gempackagetask' require 'rake/rdoctask' -require 'rake/contrib/rubyforgepublisher' require 'rake/contrib/sshpublisher' require 'fileutils' require 'spec/rake/spectask' include FileUtils @@ -17,12 +16,11 @@ NAME = "net-irc" AUTHOR = "cho45" EMAIL = "cho45@lowreal.net" DESCRIPTION = "library for implementing IRC server and client" -RUBYFORGE_PROJECT = "lowreal" -HOMEPATH = "http://#{RUBYFORGE_PROJECT}.rubyforge.org" +HOMEPATH = "http://cho45.stfuawsc.com/net-irc/" BIN_FILES = %w( ) VERS = Net::IRC::VERSION.dup REV = File.read(".svn/entries")[/committed-rev="(d+)"/, 1] rescue nil CLEAN.include ['**/.*.sw?', '*.gem', '.config'] @@ -55,11 +53,10 @@ s.description = DESCRIPTION s.author = AUTHOR s.email = EMAIL s.homepage = HOMEPATH s.executables = BIN_FILES - s.rubyforge_project = RUBYFORGE_PROJECT s.bindir = "bin" s.require_path = "lib" s.autorequire = "" #s.add_dependency('activesupport', '>=1.3.1') @@ -87,11 +84,15 @@ task :uninstall => [:clean] do sh %{sudo gem uninstall #{NAME}} end +task :upload_doc => [:rdoc] do + sh %{rsync --update -avptr html/ lowreal@cho45.stfuawsc.com:/virtual/lowreal/public_html/cho45.stfuawsc.com/net-irc} +end + Rake::RDocTask.new do |rdoc| rdoc.rdoc_dir = 'html' rdoc.options += RDOC_OPTS rdoc.template = "resh" #rdoc.template = "#{ENV['template']}.rb" if ENV['template'] @@ -102,26 +103,16 @@ rdoc.rdoc_files.include('lib/**/*.rb') rdoc.rdoc_files.include('ext/**/*.c') end end -desc "Publish to RubyForge" -task :rubyforge => [:rdoc, :package] do - require 'rubyforge' - @local_dir = "html" - @host = "cho45@rubyforge.org" - @remote_dir = "/var/www/gforge-projects/#{RUBYFORGE_PROJECT}/#{NAME}" - sh %{rsync -r --delete --verbose #{@local_dir}/ #{@host}:#{@remote_dir}} -end - Rake::ShipitTask.new do |s| - s.Step.new { - system("svn", "up") - }.and {} s.ChangeVersion "lib/net/irc.rb", "VERSION" s.Commit - s.Task :clean, :package - s.RubyForge + s.Task :clean, :package, :upload_doc + s.Step.new { + }.and { + system("gem", "push", "pkg/net-irc-#{VERS}.gem") + } s.Tag s.Twitter - s.Task :rubyforge end