class Middleman::Sources
def initialize(app, options={}, watchers=[])
def initialize(app, options={}, watchers=[]) @app = app @watchers = watchers @sorted_watchers = @watchers.dup.freeze @options = options # Set of procs wanting to be notified of changes @on_change_callbacks = [] # Global ignores @ignores = {} # Whether we're "running", which means we're in a stable # watch state after all initialization and config. @running = false @update_count = 0 @last_update_count = -1 # When the app is about to shut down, stop our watchers. @app.before_shutdown(&method(:stop!)) end