Rakefile in rio-0.3.9 vs Rakefile in rio-0.4.0
- old
+ new
@@ -41,11 +41,12 @@
$:.push 'lib'
require 'rio/version'
require 'rio/doc'
require 'rio'
-SVN_REPOSITORY_URL = 'svn+ssh://rio4ruby@rubyforge.org//var/svn/trunk/rio'
+SVN_REPOSITORY_ROOT = 'svn+ssh://rio4ruby@rubyforge.org//var/svn/rio'
+SVN_REPOSITORY_URL = [SVN_REPOSITORY_ROOT,'trunk/rio'].join('/')
require 'doc/pkg_def'
ZIP_DIR = "/zip/ruby/rio"
@@ -116,13 +117,10 @@
puts "Generating VERSION file"
File.open( 'VERSION', 'w+' ) do |file| file.write( PKG::VERSION + "\n" ) end
end
-#task :gen_files => [:gen_changelog, :gen_version, :gen_installrb]
-#CLOBBER << "ChangeLog" << "VERSION" << "install.rb"
-
task :gen_files => [:gen_changelog, :gen_version]
#task :gen_files => [:gen_version]
CLOBBER << "ChangeLog" << "VERSION"
task :no_old_pkg do
# unless Dir["pkg/#{PKG::FULLNAME}*"].empty?
@@ -146,12 +144,12 @@
Spec = Gem::Specification.new do |s|
s.name = PKG::NAME
s.version = PKG::VERSION
s.author = PKG::AUTHOR
s.email = PKG::EMAIL
- s.homepage = "http://rio.rubyforge.org/"
- s.rubyforge_project = "rio"
+ s.homepage = PKG::HOMEPAGE
+ s.rubyforge_project = PKG::RUBYFORGE_PROJECT
s.platform = Gem::Platform::RUBY
s.summary = PKG::SUMMARY
s.files = PKG::FILES::DIST.map { |rf| rf.to_s }
@@ -166,11 +164,10 @@
Rake::GemPackageTask.new(Spec) do |p| end
desc "Build the Gem spec file for the rio package"
task :gemspec => "pkg/rio.gemspec"
file "pkg/rio.gemspec" => ["pkg", "Rakefile"] do |t|
- puts PKG::FILES::DIST
open(t.name, "w") do |f| f.puts Spec.to_yaml end
end
desc "Make a new release (test,package,svn_version)"
task :release => [:test, :clobber, :rdoc , :package, :svn_version, :ziparc] do
@@ -179,11 +176,12 @@
end
desc "Save the current code as a new svn version"
task :svn_version do
require 'rio'
repos = rio(SVN_REPOSITORY_URL)
- proju = rio(repos,PKG::NAME,'trunk')
- relu = rio(repos,PKG::NAME,'tags','release-') + PKG::VERSION
+ repo_root = rio(SVN_REPOSITORY_ROOT)
+ proju = rio(repo_root,'trunk',PKG::NAME)
+ relu = rio(repo_root,'tags',"release-#{PKG::VERSION}")
relo =`svn list #{relu.to_url}`
if relo.size > 0
$stderr.puts "Release #{relu.to_url} exists!"
exit(-1)
end