module Capacitor
Constants
- VERSION
Attributes
logger[W]
Public Class Methods
log_level=(level)
click to toggle source
# File lib/capacitor.rb, line 19 def log_level=(level) return unless level begin level = Logger.const_get level.upcase if level.is_a?(String) logger.level = level rescue Exception => e logger.error "Unable to set log level to #{level} - #{e}" end end
logger()
click to toggle source
# File lib/capacitor.rb, line 15 def logger @logger ||= const_defined?(:Rails) ? Rails.logger : Logger.new(STDOUT) end
redis()
click to toggle source
# File lib/capacitor.rb, line 33 def redis @redis ||= Redis::Namespace.new :capacitor, redis: Redis.current end
redis=(redis)
click to toggle source
# File lib/capacitor.rb, line 29 def redis=(redis) @redis = Redis::Namespace.new :capacitor, redis: redis end
run()
click to toggle source
# File lib/capacitor.rb, line 37 def run STDOUT.sync = true Watcher.run end