Permalink
Browse files

Fix release task

  • Loading branch information...
1 parent 30a0c96 commit ceaf84a458454ed1bd1cfb0050e57ac033a4bf9e @sferik sferik committed Apr 22, 2011
Showing with 16 additions and 15 deletions.
  1. +16 −15 Rakefile
View
@@ -1,4 +1,5 @@
require 'rake'
+require File.expand_path('../omniauth/lib/omniauth/version', __FILE__)
begin
require 'term/ansicolor'
@@ -30,7 +31,7 @@ task :spec do
error_gems << gem
end
end
-
+
puts
if error_gems.any?
puts "#{red}#{error_gems.size} gems with failing specs: #{error_gems.join(', ')}#{clear}"
@@ -40,34 +41,34 @@ task :spec do
end
end
-task :release => ['release:tag', 'gems:publish', 'doc:pages:publish']
+desc "Release all gems to gemcutter and create a tag"
+task :release => ['tag', 'clean', 'build', 'publish']
+
+task :tag do
+ system("git tag v#{Omniauth::VERSION}")
+ system('git push origin --tags')
+end
-desc 'Push all gems to Gemcutter'
-task :push do
- each_gem('is releasing to Gemcutter...') do
- system('rake release')
+task :publish do
+ each_gem('is releasing to Rubygems...') do
+ system('gem push pkg/*.gem')
end
end
-desc 'Build all gems'
+desc "Build gem files for all projects"
task :build do
each_gem('is building gems...') do
system('rake build')
end
end
-desc 'Install all gems'
+desc "Install gems for all projects"
task :install do
each_gem('is installing gems...') do
system('rake install')
end
end
-desc "Uninstall gems"
-task :uninstall do
- sh "sudo gem uninstall #{OMNIAUTH_GEMS.join(" ")} -a"
-end
-
desc "Clean pkg and other stuff"
task :clean do
OMNIAUTH_GEMS.each do |dir|
@@ -86,12 +87,12 @@ begin
YARD::Rake::YardocTask.new(:doc) do |t|
t.files = OMNIAUTH_GEMS.inject([]){|a,g| a = a + ["#{g}/lib/**/*.rb"]; a} + ['README.markdown']
end
-
+
namespace :doc do
YARD::Rake::YardocTask.new(:pages) do |t|
t.files = OMNIAUTH_GEMS.inject([]){|a,g| a = a + ["#{g}/lib/**/*.rb"]; a} + ['README.markdown']
end
-
+
namespace :pages do
desc 'Generate and publish YARD docs to GitHub pages.'
task :publish => ['doc:pages'] do

0 comments on commit ceaf84a

Please sign in to comment.