class Runter::Application
Public Class Methods
new()
click to toggle source
# File lib/runter/application.rb, line 6 def initialize @name = "runter" @runtFile = Runter::Runtfile.new end
Public Instance Methods
handle_change(file)
click to toggle source
# File lib/runter/application.rb, line 26 def handle_change(file) @runtFile.get_watchers().each{|watcher| watcher.handle_change(file) } end
run()
click to toggle source
# File lib/runter/application.rb, line 11 def run puts "Runter started..." start_watch() end
start_watch()
click to toggle source
# File lib/runter/application.rb, line 16 def start_watch() filesToWatch = [] @runtFile.get_watchers().each{|watcher| filesToWatch.push(*watcher.get_watch_files()) } FileWatcher.new(filesToWatch).watch() do |filename, event| handle_change(filename) end end