tasks/gem.rake in addressable-2.3.7 vs tasks/gem.rake in addressable-2.3.8
- old
+ new
@@ -16,21 +16,20 @@
if !s.respond_to?(:add_development_dependency)
puts "Cannot build Gem with this version of RubyGems."
exit(1)
end
- s.add_development_dependency 'rake', '~> 0.7', '>= 0.7.3'
+ s.add_development_dependency 'rake', '~> 10.4', '>= 10.4.2'
s.add_development_dependency 'rspec', '~> 3.0'
s.add_development_dependency 'rspec-its', '~> 1.1'
- s.add_development_dependency 'launchy', '~> 0.3', '>= 0.3.2'
+ s.add_development_dependency 'launchy', '~> 2.4', '>= 2.4.3'
s.require_path = "lib"
s.author = "Bob Aman"
s.email = "bob@sporkmonger.com"
- s.homepage = RUBY_FORGE_URL
- s.rubyforge_project = RUBY_FORGE_PROJECT
+ s.homepage = "https://github.com/sporkmonger/addressable"
s.license = "Apache License 2.0"
end
Gem::PackageTask.new(GEM_SPEC) do |p|
p.gem_spec = GEM_SPEC
@@ -75,9 +74,21 @@
end
end
desc "Reinstall the gem"
task :reinstall => [:uninstall, :install]
+
+ desc 'Package for release'
+ task :release => ["gem:package", "gem:gemspec"] do |t|
+ v = ENV['VERSION'] or abort 'Must supply VERSION=x.y.z'
+ abort "Versions don't match #{v} vs #{PROJ.version}" if v != PKG_VERSION
+ pkg = "pkg/#{GEM_SPEC.full_name}"
+
+ changelog = File.open("CHANGELOG.md") { |file| file.read }
+
+ puts "Releasing #{PKG_NAME} v. #{PKG_VERSION}"
+ Rake::Task["git:tag:create"].invoke
+ end
end
desc "Alias to gem:package"
task "gem" => "gem:package"