quality 0.2.9 → 0.2.10

Sign up to get free protection for your applications and to get access to all the features.
@@ -38,6 +38,11 @@ module Quality
38
38
  # Defaults to []
39
39
  attr_accessor :skip_tools
40
40
 
41
+ # Array of directory names which contain ruby files to analyze.
42
+ #
43
+ # Defaults to %w{lib test features}, which translates to *.rb in the base directory, as well as lib, test, and features.
44
+ attr_writer :ruby_dirs
45
+
41
46
  # Defines a new task, using the name +name+.
42
47
  def initialize(args = {})
43
48
  @name = args[:name]
@@ -159,8 +164,12 @@ module Quality
159
164
  }
160
165
  end
161
166
 
167
+ def ruby_dirs
168
+ @ruby_dirs ||= %w{lib test features}
169
+ end
170
+
162
171
  def ruby_files
163
- Dir.glob('*.rb').concat(Dir.glob(File.join('{lib,test}', '**', '*.rb'))).join(' ')
172
+ Dir.glob('*.rb').concat(Dir.glob(File.join("{#{ruby_dirs.join(',')}}", '**', '*.rb'))).join(' ')
164
173
  end
165
174
 
166
175
  def quality_reek
@@ -1,3 +1,3 @@
1
1
  module Quality
2
- VERSION = '0.2.9'
2
+ VERSION = '0.2.10'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: quality
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.9
4
+ version: 0.2.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-09-12 00:00:00.000000000 Z
12
+ date: 2013-09-27 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: cane