Sha256: 06953924a2d07afa8d9acc77e2cf93e57f8fbbf26d769812d3ea84648fc21668

Contents?: true

Size: 560 Bytes

Versions: 5

Compression:

Stored size: 560 Bytes

Contents

require 'redis'
require 'pathname'

require 'wolverine/version'
require 'wolverine/configuration'
require 'wolverine/script'
require 'wolverine/path_component'

module Wolverine
  def self.config
    @config ||= Configuration.new
  end

  def self.redis
    config.redis
  end

  def self.reset!
    @root_directory = nil
  end

  def self.root_directory
    @root_directory ||= PathComponent.new(config.script_path)
  end

  def self.method_missing sym, *args
    root_directory.send(sym, *args) 
  rescue PathComponent::MissingTemplate
    super 
  end

end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
wolverine-0.2.1 lib/wolverine.rb
wolverine-0.2.0 lib/wolverine.rb
wolverine-0.1.3 lib/wolverine.rb
wolverine-0.1.2 lib/wolverine.rb
wolverine-0.1.1 lib/wolverine.rb