Skip to content

error using standard watch syntax #25

@brewster1134

Description

@brewster1134

So based on the example provided through guard init coffeescript, i can get it working... however i prefer the approach of calling multiple watch methods explicitly, however that does not seem to work with this guard plugin.

# this works
coffeescript_options = {
  input: '.',
  output: '.dist',
  patterns: [%r{^(.+\.(?:coffee|coffee\.md|litcoffee))$}]
}

guard :coffeescript, coffeescript_options do
  coffeescript_options[:patterns].each { |pattern| watch(pattern) }
end
# this does NOT work
guard :coffeescript, input: '.', output: '.dist' do
  watch(%r{^(.+\.(?:coffee|coffee\.md|litcoffee))$})
end

also (despite the examples in the README), without providing an input value, throws the error :input option not provided (see current template Guardfile)

having all my guard plugin declarations contained to the guard block makes my larger Guardfile much easier to read, so hopefully i just have some syntax incorrect.

ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-darwin14]
Guard version 2.13.0
guard-coffeescript (2.0.1)

thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions