Class: ShopifyThemeBuilder::Filewatcher

Inherits:
Object
  • Object
show all
Defined in:
lib/shopify_theme_builder/filewatcher.rb

Overview

It wraps the Filewatcher functionality to monitor file changes. It delegates method calls to the underlying Filewatcher instance. Check: https://github.com/filewatcher/filewatcher

Instance Method Summary collapse

Constructor Details

#initialize ⇒ Filewatcher

Returns a new instance of Filewatcher.



10
11
12
# File 'lib/shopify_theme_builder/filewatcher.rb', line 10

def initialize(...)
  @filewatcher = ::Filewatcher.new(...)
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(name) ⇒ Object



14
15
16
17
18
19
20
# File 'lib/shopify_theme_builder/filewatcher.rb', line 14

def method_missing(name, ...)
  if @filewatcher.respond_to?(name)
    @filewatcher.send(name, ...)
  else
    super
  end
end

Instance Method Details

#respond_to_missing?(name, include_private) ⇒ Boolean

Returns:

  • (Boolean)


22
23
24
# File 'lib/shopify_theme_builder/filewatcher.rb', line 22

def respond_to_missing?(name, include_private)
  @filewatcher.respond_to?(name) || super
end