Sha256: c780e8dbadb1e1ffca4c5e0306e57e30c9a166f880484f52c639fdee148e2f29

Contents?: true

Size: 493 Bytes

Versions: 6

Compression:

Stored size: 493 Bytes

Contents

def run(cmd, msg = nil)
  puts "=== %s" % msg if msg
  puts "=== %s" % cmd
  system cmd
  puts "\n"
end

watch("spec/.*_spec\.rb") { |m| run("bundle exec rspec %s" % m[0]) }
watch("lib/allowance/(.*)\.rb") { |m| run("bundle exec rspec spec/%s_spec.rb" % m[1]) }
watch('^spec/(spec_helper|factories)\.rb') { |f| run "bundle exec rake spec", "%s.rb has been modified" % f }

# Ctrl-\
Signal.trap('QUIT')   { run("bundle exec rake spec") }
# Ctrl-C
Signal.trap('INT')    { abort("\nQuitting.") }

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
allowance-0.2.0 .watchr
allowance-0.1.1 .watchr
allowance-0.1.0 .watchr
allowance-0.0.4 .watchr
allowance-0.0.3 .watchr
allowance-0.0.2 .watchr