lib/brwy_rails/runner.rb in brwy_rails-0.0.1 vs lib/brwy_rails/runner.rb in brwy_rails-0.0.2

- old
+ new

@@ -24,10 +24,14 @@ private def watching? @config.watch end + def polling? + @config.poll + end + def run_with_watchify(target) ensure_output_dir! spawn watchify_cmd(target), chdir: Rails.root end @@ -39,10 +43,10 @@ def browserify_cmd(target) "node_modules/.bin/browserify #{cmd target}" end def watchify_cmd(target) - "node_modules/.bin/watchify #{cmd target} #{verbose? ? "-v" : ""}" + "node_modules/.bin/watchify #{cmd target} #{verbose? ? "-v" : ""} #{polling? ? "--poll=#{@config.polling_interval}" : ""}" end def cmd(target) "#{@config.browserify_opts} -o #{output_path(target)} #{src_path(target)}" end