forked from jaredmdobson/rack-livereload
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGuardfile
29 lines (23 loc) · 741 Bytes
/
Guardfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# A sample Guardfile
# More info at https://github.com/guard/guard#readme
guard 'rspec', :cmd => 'rspec -c' do
watch(%r{^spec/.+_spec\.rb$})
watch(%r{^lib/(.+)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" }
watch('spec/spec_helper.rb') { "spec" }
end
guard 'livereload' do
watch('index.html')
end
guard 'cucumber' do
watch(%r{^features/.+\.feature$})
watch(%r{^features/support/.+$}) { 'features' }
end
guard :bundler do
require 'guard/bundler'
require 'guard/bundler/verify'
helper = Guard::Bundler::Verify.new
files = ['Gemfile']
files += Dir['*.gemspec'] if files.any? { |f| helper.uses_gemspec?(f) }
# Assume files are symlinked from somewhere
files.each { |file| watch(helper.real_path(file)) }
end