Skip to content
Browse files

use bundler for

  • Loading branch information...
1 parent 2e2927a commit 64180d9279aeb388529ffe53c32dad537ce7f616 @staugaard staugaard committed Dec 17, 2010
Showing with 72 additions and 46 deletions.
  1. +1 −1 .gitignore
  2. +3 −0 Gemfile
  3. +39 −0 Gemfile.lock
  4. +2 −45 Rakefile
  5. +23 −0 resque-multi-job-forks.gemspec
  6. +4 −0 test/helper.rb
View
2 .gitignore
@@ -17,6 +17,6 @@ tmtags
coverage
rdoc
pkg
-*.gemspec
+.bundle
## PROJECT::SPECIFIC
View
3 Gemfile
@@ -0,0 +1,3 @@
+source 'http://rubygems.org'
+
+gemspec
View
39 Gemfile.lock
@@ -0,0 +1,39 @@
+PATH
+ remote: .
+ specs:
+ resque-multi-job-forks (0.2.0)
+ json
+ redis (< 2.0)
+ resque (< 1.8.0)
+
+GEM
+ remote: http://rubygems.org/
+ specs:
+ json (1.4.6)
+ rack (1.2.1)
+ rake (0.8.7)
+ redis (1.0.7)
+ redis-namespace (0.10.0)
+ redis (< 3.0.0)
+ resque (1.7.1)
+ redis
+ redis-namespace
+ sinatra (>= 0.9.2)
+ vegas (>= 0.1.2)
+ sinatra (1.1.0)
+ rack (~> 1.1)
+ tilt (~> 1.1)
+ tilt (1.1)
+ vegas (0.1.8)
+ rack (>= 1.0.0)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ bundler
+ json
+ rake
+ redis (< 2.0)
+ resque (< 1.8.0)
+ resque-multi-job-forks!
View
47 Rakefile
@@ -1,23 +1,5 @@
-require 'rubygems'
-require 'rake'
-
-begin
- require 'jeweler'
- Jeweler::Tasks.new do |gem|
- gem.name = "resque-multi-job-forks"
- gem.version = "0.2.0"
- gem.summary = %Q{Have your resque workers process more that one job}
- gem.description = %Q{When your resque jobs are frequent and fast,
- the overhead of forking and running your after_fork might get too big.}
- gem.email = "mick@staugaard.com"
- gem.homepage = "http://github.com/staugaard/resque-multi-job-forks"
- gem.authors = ["Mick Staugaard"]
- gem.add_dependency "resque", "< 1.8.0"
- end
- Jeweler::GemcutterTasks.new
-rescue LoadError
- puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
-end
+require 'bundler'
+Bundler::GemHelper.install_tasks
require 'rake/testtask'
Rake::TestTask.new(:test) do |test|
@@ -26,29 +8,4 @@ Rake::TestTask.new(:test) do |test|
test.verbose = true
end
-begin
- require 'rcov/rcovtask'
- Rcov::RcovTask.new do |test|
- test.libs << 'test'
- test.pattern = 'test/**/test_*.rb'
- test.verbose = true
- end
-rescue LoadError
- task :rcov do
- abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
- end
-end
-
-task :test => :check_dependencies
-
task :default => :test
-
-require 'rake/rdoctask'
-Rake::RDocTask.new do |rdoc|
- version = File.exist?('VERSION') ? File.read('VERSION') : ""
-
- rdoc.rdoc_dir = 'rdoc'
- rdoc.title = "resque-multi-job-forks #{version}"
- rdoc.rdoc_files.include('README*')
- rdoc.rdoc_files.include('lib/**/*.rb')
-end
View
23 resque-multi-job-forks.gemspec
@@ -0,0 +1,23 @@
+# -*- encoding: utf-8 -*-
+$:.push File.expand_path("../lib", __FILE__)
+
+Gem::Specification.new do |s|
+ s.name = "resque-multi-job-forks"
+ s.version = "0.2.0"
+ s.authors = ["Mick Staugaard"]
+ s.email = ["mick@zendesk.com"]
+ s.homepage = "http://github.com/staugaard/resque-multi-job-forks"
+ s.summary = "Have your resque workers process more that one job"
+ s.description = "When your resque jobs are frequent and fast, the overhead of forking and running your after_fork might get too big."
+
+ s.add_runtime_dependency("resque", "< 1.8.0")
+ s.add_runtime_dependency("redis", "< 2.0")
+ s.add_runtime_dependency("json")
+
+ s.add_development_dependency("rake")
+ s.add_development_dependency("bundler")
+
+ s.files = Dir["lib/**/*"]
+ s.test_files = Dir["test/**/*"]
+ s.require_paths = ["lib"]
+end
View
4 test/helper.rb
@@ -1,6 +1,10 @@
require 'rubygems'
require 'test/unit'
+require 'bundler'
+Bundler.setup
+Bundler.require
+
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
$LOAD_PATH.unshift(File.dirname(__FILE__))
$TESTING = true

0 comments on commit 64180d9

Please sign in to comment.
Something went wrong with that request. Please try again.