Sha256: dae3e550c3f311e68358dd4a9c25590780252589dcbb34509e0574bc3b3e00bc
Contents?: true
Size: 676 Bytes
Versions: 1
Compression:
Stored size: 676 Bytes
Contents
require "spring-jruby/watcher/abstract" require "spring-jruby/configuration" module Spring class << self attr_accessor :watch_interval attr_writer :watcher attr_reader :watch_method end def self.watch_method=(method) if method.is_a?(Class) @watch_method = method else require "spring-jruby/watcher/#{method}" @watch_method = Watcher.const_get(method.to_s.gsub(/(^.|_.)/) { $1[-1].upcase }) end end self.watch_interval = 0.2 self.watch_method = :polling def self.watcher @watcher ||= watch_method.new(Spring.application_root_path, watch_interval) end def self.watch(*items) watcher.add(*items) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
spring-jruby-1.4.3 | lib/spring-jruby/watcher.rb |