Sha256: 4d97f5fa9b1da1f520bd1078308e1130dc9d155982a81573b8915539b58996ec

Contents?: true

Size: 835 Bytes

Versions: 4

Compression:

Stored size: 835 Bytes

Contents

# A sample Guardfile
# More info at https://github.com/guard/guard#readme
# ignore(/\/.#.+/)

guard :rubocop, all_on_start: false, keep_failed: false, notification: false, cli: ['--format', 'emacs'] do
  watch(/^app\/(.+)\.rb$/)
  watch(/^lib\/(.+)\.rb$/)
  watch(/^spec\/(.+)\.rb$/)
end

guard :rspec, cmd: 'bundle exec rspec' do
  watch(/^spec\/.+_spec\.rb$/)
  watch(/^spec\/spec_helper\.rb$/) { 'spec' }
  watch(/^app\/(.+)\.rb$/)         { |m| "spec/#{m[1]}_spec.rb" }
  watch(/^lib\/(.+)\.rb$/)         { |m| "spec/lib/#{m[1]}_spec.rb" }
  watch(%r{^app/models/concerns/(.+)\.rb$}) { |_m| 'spec/models/*._spec.rb' }
  watch(%r{^app/controllers/(.+)_(controller)\.rb$}) do |m|
    [
      "spec/routing/#{m[1]}_routing_spec.rb",
      "spec/#{m[2]}s/#{m[1]}_#{m[2]}_spec.rb",
      "spec/requests/#{m[1]}_spec.rb"
    ]
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
geopolitical-3.0.0 Guardfile
geopolitical-2.0.0 Guardfile
geopolitical-1.0.5 Guardfile
geopolitical-1.0.3 Guardfile