Sha256: e2f8258d2987445ffe73191446cba318b57d84292455b7b94f8c2c4433260ec1

Contents?: true

Size: 470 Bytes

Versions: 6

Compression:

Stored size: 470 Bytes

Contents

module RedisKit
  class Railtie < Rails::Railtie
    initializer "redis-kit.setup_redis" do |app|
      # Register the path with Rails so that users can change it, if they want.
      unless app.paths["config/redis"]
        app.paths.add "config/redis", with: "config/redis.yml"
      end

      # Set up a new global Redis connection.
      path = app.paths["config/redis"].first
      env = Rails.env
      $redis = RedisKit.new_redis( path, env )
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
redis-kit-0.1.0 lib/redis-kit/railtie.rb
redis-kit-0.0.6 lib/redis-kit/railtie.rb
redis-kit-0.0.5 lib/redis-kit/railtie.rb
redis-kit-0.0.4 lib/redis-kit/railtie.rb
redis-kit-0.0.3 lib/redis-kit/railtie.rb
redis-kit-0.0.2 lib/redis-kit/railtie.rb