Closed semperos closed 12 years ago
Here is my Guardfile:
group :backend do guard 'jruby-rspec', :spec_paths => ["spec/ruby"], :cli => ["-t~integration:true", "--color"] do watch %r{^spec/ruby/.+_spec\.rb$} watch(%r{^helpers/.+\.rb$}) { 'spec' } watch(%r{^models/.+\.rb$}) { 'spec' } watch(%r{^views/.+\.rb$}) { 'spec' } watch(%r{^lib/(.+)\.rb$}) { 'spec' } # { |m| "spec/ruby/lib/#{m[1]}_spec.rb" } watch(%r{^apps/.+\.rb$}) { 'spec' } watch('spec/ruby/spec_helper.rb') { 'spec' } watch('spec/ruby/app_helper.rb') { 'spec' } end end
When I save a spec file that matches the regex for the first watcher, I get the following error:
ERROR: Problem with watch action! undefined method `arity' for nil:NilClass /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard/watcher.rb:121:in `call_action' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/bundler/gems/guard-jruby-rspec-75e2562e19d7/lib/guard/jruby-rspec.rb:60:in `run_on_change' org/jruby/RubyArray.java:1615:in `each' (eval):3:in `each_with_optional_block' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/bundler/gems/guard-jruby-rspec-75e2562e19d7/lib/guard/jruby-rspec.rb:59:in `run_on_change' org/jruby/RubyArray.java:1615:in `each' (eval):3:in `each_with_optional_block' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/bundler/gems/guard-jruby-rspec-75e2562e19d7/lib/guard/jruby-rspec.rb:58:in `run_on_change' org/jruby/RubyBasicObject.java:1704:in `__send__' org/jruby/RubyKernel.java:2101:in `send' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:395:in `run_supervised_task' org/jruby/RubyKernel.java:1197:in `catch' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:393:in `run_supervised_task' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:349:in `run_on_change_task' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:287:in `run_on_change' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:327:in `run_on_guards' org/jruby/RubyArray.java:1615:in `each' (eval):3:in `each_with_optional_block' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:326:in `run_on_guards' org/jruby/RubyKernel.java:1197:in `catch' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:325:in `run_on_guards' org/jruby/RubyArray.java:1615:in `each' (eval):3:in `each_with_optional_block' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:324:in `run_on_guards' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:286:in `run_on_change' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:303:in `run' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:300:in `run' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard.rb:285:in `run_on_change' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard/listener.rb:235:in `start_reactor' org/jruby/RubyKernel.java:1410:in `loop' /Users/semperos/.rbenv/versions/jruby-1.6.7/lib/ruby/gems/1.8/gems/guard-1.0.3/lib/guard/listener.rb:231:in `start_reactor'
that's what i was expecting. I'm not handling that first watcher. i'll fix that -- should be easy.
will be available in 0.1.3
Great, thank you.
Here is my Guardfile:
When I save a spec file that matches the regex for the first watcher, I get the following error: