Class: Bently::ResqueRails

Inherits:
RailsRecipe show all
Defined in:
lib/bently/recipe/resque-rails.rb

Constant Summary

Constants inherited from RubyRecipe

Bently::RubyRecipe::GEMFILE

Instance Method Summary collapse

Methods inherited from RailsRecipe

#generate, #migrate

Methods inherited from RubyRecipe

#bundle, #gem, #gem_group

Methods inherited from Recipe

#append, breakdown, category, #code, #create, description, homepage, #insert, #modify, #operate, #operations, #prepend, #remove, #requirement, #run, #say, title, #todo, #usage, version, #warn

Constructor Details

#initializeResqueRails

Returns a new instance of ResqueRails.



7
8
9
10
11
12
13
14
15
16
# File 'lib/bently/recipe/resque-rails.rb', line 7

def initialize
  requirement "redis (OS X: \`brew install redis\`, \`redis-server /usr/local/etc/redis.conf\`)"
  gem 'resque'
  bundle
  create 'lib/tasks/resque.rake', "require 'resque/tasks'"
  todo 'redis-server'
  todo "If you want to use the front end, add to config/routes.rb:"
  say "require 'resque/server'", ''
  say '  mount Resque::Server, :at => "/resque"', ''
end