Method: Guard.changed_paths

Defined in:
lib/guard.rb

.changed_paths(paths) ⇒ Array<String>

Detects the paths that have changed.

Deleted paths are prefixed by an exclamation point.

Parameters:

  • paths (Array<String>)

    the watched paths

Returns:

  • (Array<String>)

    the changed paths

See Also:



293
294
295
# File 'lib/guard.rb', line 293

def changed_paths(paths)
  paths.select { |f| !f.respond_to?(:start_with?) || !f.start_with?('!') }
end