Skip to content

Commit

Permalink
Update to finstyle 1.2.0.
Browse files Browse the repository at this point in the history
  • Loading branch information
fnichol committed Sep 2, 2014
1 parent b63b4fb commit 679f057
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 18 deletions.
15 changes: 8 additions & 7 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
source 'https://rubygems.org'
# -*- encoding: utf-8 -*-
source "https://rubygems.org"

gemspec

group :guard do
gem 'guard-minitest'
gem 'guard-rubocop'
gem 'guard-cane'
gem 'guard-yard'
gem "guard-minitest"
gem "guard-rubocop"
gem "guard-cane"
gem "guard-yard"
end

group :test do
# allow CI to override the version of Chef for matrix testing
gem 'chef', (ENV['CHEF_VERSION'] || '>= 0.10.10')
gem "chef", (ENV["CHEF_VERSION"] || ">= 0.10.10")

gem 'codeclimate-test-reporter', require: nil
gem "codeclimate-test-reporter", :require => nil
end
37 changes: 27 additions & 10 deletions Guardfile
Original file line number Diff line number Diff line change
@@ -1,23 +1,40 @@
# -*- encoding: utf-8 -*-
ignore %r{^\.gem/}

group :red_green_refactor, halt_on_fail: true do
guard :minitest do
watch(%r|^spec/(.*)_spec\.rb|)
watch(%r|^lib/(.*)([^/]+)\.rb|) { |m| "spec/unit/#{m[1]}#{m[2]}_spec.rb" }
watch(%r|^spec/spec_helper\.rb|) { "spec" }
def minitest_opts
{}
end

def cane_opts
{}
end

def rubocop_opts
{ :all_on_start => false, :keep_failed => false, :cli => "-r finstyle -D" }
end

def yard_opts
{ :port => 8808 }
end

group :red_green_refactor, :halt_on_fail => true do
guard :minitest, minitest_opts do
watch(%r{^spec/(.*)_spec\.rb})
watch(%r{^lib/(.*)([^/]+)\.rb}) { |m| "spec/unit/#{m[1]}#{m[2]}_spec.rb" }
watch(%r{^spec/spec_helper\.rb}) { "spec" }
end

guard :cane do
watch(%r|.*\.rb|)
watch('.cane')
guard :cane, cane_opts do
watch(%r{.*\.rb})
watch(".cane")
end

guard :rubocop, all_on_start: false, keep_failed: false, cli: "-r finstyle" do
guard :rubocop, rubocop_opts do
watch(%r{.+\.rb$})
watch(%r{(?:.+/)?\.rubocop\.yml$}) { |m| File.dirname(m[0]) }
end
end

guard :yard, port: "8808" do
guard :yard, yard_opts do
watch(%r{lib/.+\.rb})
end
2 changes: 1 addition & 1 deletion emeril.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,6 @@ Gem::Specification.new do |spec|
# style and complexity libraries are tightly version pinned as newer releases
# may introduce new and undesireable style choices which would be immediately
# enforced in CI
spec.add_development_dependency "finstyle", "1.1.0"
spec.add_development_dependency "finstyle", "1.2.0"
spec.add_development_dependency "cane", "2.6.2"
end

0 comments on commit 679f057

Please sign in to comment.