rubocop 0.31.0 → 0.32.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of rubocop might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/CHANGELOG.md +50 -0
- data/README.md +13 -0
- data/config/disabled.yml +4 -0
- data/config/enabled.yml +34 -8
- data/lib/rubocop.rb +4 -1
- data/lib/rubocop/cop/cop.rb +18 -12
- data/lib/rubocop/cop/lint/debugger.rb +7 -1
- data/lib/rubocop/cop/lint/duplicate_methods.rb +1 -1
- data/lib/rubocop/cop/lint/literal_in_interpolation.rb +10 -0
- data/lib/rubocop/cop/lint/nested_method_definition.rb +31 -0
- data/lib/rubocop/cop/lint/non_local_exit_from_iterator.rb +9 -0
- data/lib/rubocop/cop/lint/unneeded_disable.rb +53 -0
- data/lib/rubocop/cop/metrics/class_length.rb +1 -1
- data/lib/rubocop/cop/metrics/module_length.rb +1 -1
- data/lib/rubocop/cop/metrics/parameter_lists.rb +1 -1
- data/lib/rubocop/cop/mixin/autocorrect_alignment.rb +1 -1
- data/lib/rubocop/cop/mixin/if_node.rb +10 -0
- data/lib/rubocop/cop/mixin/space_after_punctuation.rb +8 -1
- data/lib/rubocop/cop/mixin/space_before_punctuation.rb +8 -1
- data/lib/rubocop/cop/mixin/statement_modifier.rb +2 -5
- data/lib/rubocop/cop/mixin/string_help.rb +1 -1
- data/lib/rubocop/cop/offense.rb +16 -3
- data/lib/rubocop/cop/performance/count.rb +33 -30
- data/lib/rubocop/cop/performance/sample.rb +103 -59
- data/lib/rubocop/cop/performance/size.rb +2 -1
- data/lib/rubocop/cop/rails/time_zone.rb +14 -6
- data/lib/rubocop/cop/style/align_hash.rb +7 -3
- data/lib/rubocop/cop/style/braces_around_hash_parameters.rb +39 -11
- data/lib/rubocop/cop/style/case_indentation.rb +18 -4
- data/lib/rubocop/cop/style/comment_annotation.rb +22 -7
- data/lib/rubocop/cop/style/documentation.rb +11 -5
- data/lib/rubocop/cop/style/empty_else.rb +25 -0
- data/lib/rubocop/cop/style/if_unless_modifier.rb +1 -5
- data/lib/rubocop/cop/style/indentation_width.rb +1 -5
- data/lib/rubocop/cop/style/multiline_operation_indentation.rb +12 -10
- data/lib/rubocop/cop/style/next.rb +1 -1
- data/lib/rubocop/cop/style/parallel_assignment.rb +196 -0
- data/lib/rubocop/cop/style/single_line_methods.rb +1 -4
- data/lib/rubocop/cop/style/space_inside_string_interpolation.rb +41 -0
- data/lib/rubocop/cop/style/struct_inheritance.rb +11 -10
- data/lib/rubocop/cop/style/trailing_blank_lines.rb +8 -0
- data/lib/rubocop/cop/style/trailing_comma.rb +1 -1
- data/lib/rubocop/cop/team.rb +8 -1
- data/lib/rubocop/formatter/disabled_config_formatter.rb +2 -1
- data/lib/rubocop/formatter/formatter_set.rb +24 -1
- data/lib/rubocop/options.rb +4 -0
- data/lib/rubocop/processed_source.rb +4 -1
- data/lib/rubocop/runner.rb +12 -7
- data/lib/rubocop/target_finder.rb +3 -3
- data/lib/rubocop/version.rb +1 -1
- data/relnotes/v0.32.0.md +139 -0
- data/rubocop.gemspec +2 -2
- metadata +12 -8
- data/lib/rubocop/cop/performance/parallel_assignment.rb +0 -79
@@ -6,6 +6,7 @@ module RuboCop
|
|
6
6
|
# This cop checks for single-line method definitions.
|
7
7
|
# It can optionally accept single-line methods with no body.
|
8
8
|
class SingleLineMethods < Cop
|
9
|
+
include AutocorrectAlignment
|
9
10
|
include OnMethodDef
|
10
11
|
|
11
12
|
MSG = 'Avoid single-line method definitions.'
|
@@ -55,10 +56,6 @@ module RuboCop
|
|
55
56
|
)
|
56
57
|
end
|
57
58
|
|
58
|
-
def configured_indentation_width
|
59
|
-
config.for_cop('IndentationWidth')['Width']
|
60
|
-
end
|
61
|
-
|
62
59
|
def move_comment(eol_comment, node, corrector)
|
63
60
|
text = eol_comment.loc.expression.source
|
64
61
|
corrector.insert_before(node.loc.expression,
|
@@ -0,0 +1,41 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
|
3
|
+
module RuboCop
|
4
|
+
module Cop
|
5
|
+
module Style
|
6
|
+
# This cop checks for whitespace within string interpolations.
|
7
|
+
#
|
8
|
+
# Good:
|
9
|
+
# var = "This is the #{good} example"
|
10
|
+
#
|
11
|
+
# Bad:
|
12
|
+
# var = "This is the #{ bad } example"
|
13
|
+
#
|
14
|
+
class SpaceInsideStringInterpolation < Cop
|
15
|
+
MSG = 'Space inside string interpolation detected.'
|
16
|
+
|
17
|
+
def on_dstr(node)
|
18
|
+
node.children.select { |n| n.type == :begin }.each do |begin_node|
|
19
|
+
final_node = begin_node.children.last
|
20
|
+
|
21
|
+
interp = final_node.loc.expression
|
22
|
+
if range_with_surrounding_space(interp) != interp
|
23
|
+
add_offense(final_node, :expression)
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
private
|
29
|
+
|
30
|
+
def autocorrect(node)
|
31
|
+
lambda do |corrector|
|
32
|
+
corrector.replace(
|
33
|
+
range_with_surrounding_space(node.loc.expression),
|
34
|
+
node.loc.expression.source
|
35
|
+
)
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
@@ -25,16 +25,17 @@ module RuboCop
|
|
25
25
|
private
|
26
26
|
|
27
27
|
def struct_constructor?(node)
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
28
|
+
return false unless node
|
29
|
+
|
30
|
+
send_node = node.block_type? ? node.children.first : node
|
31
|
+
return false unless send_node.send_type?
|
32
|
+
|
33
|
+
receiver, method_name = *send_node
|
34
|
+
|
35
|
+
receiver &&
|
36
|
+
receiver.const_type? &&
|
37
|
+
receiver.children.last == :Struct &&
|
38
|
+
method_name == :new
|
38
39
|
end
|
39
40
|
end
|
40
41
|
end
|
@@ -24,6 +24,14 @@ module RuboCop
|
|
24
24
|
|
25
25
|
return unless blank_lines != wanted_blank_lines
|
26
26
|
|
27
|
+
offense_detected(sb, wanted_blank_lines, blank_lines,
|
28
|
+
whitespace_at_end)
|
29
|
+
end
|
30
|
+
|
31
|
+
private
|
32
|
+
|
33
|
+
def offense_detected(sb, wanted_blank_lines, blank_lines,
|
34
|
+
whitespace_at_end)
|
27
35
|
begin_pos = sb.source.length - whitespace_at_end.length
|
28
36
|
autocorrect_range = Parser::Source::Range.new(sb, begin_pos,
|
29
37
|
sb.source.length)
|
data/lib/rubocop/cop/team.rb
CHANGED
@@ -79,7 +79,14 @@ module RuboCop
|
|
79
79
|
cop.relevant_file?(buffer.name) && cop.corrections.any?
|
80
80
|
end
|
81
81
|
if cop_with_corrections
|
82
|
-
|
82
|
+
corrections = cop_with_corrections.corrections
|
83
|
+
# Be extra careful if there are tabs in the source and just correct
|
84
|
+
# one offense, because inserting or removing space next to a tab has
|
85
|
+
# special implications, and existing ranges can't be used after such
|
86
|
+
# a change.
|
87
|
+
corrections = [corrections.first] if buffer.source =~ /\t/
|
88
|
+
|
89
|
+
corrector = Corrector.new(buffer, corrections)
|
83
90
|
corrector.rewrite
|
84
91
|
else
|
85
92
|
buffer.source
|
@@ -55,7 +55,8 @@ module RuboCop
|
|
55
55
|
default_cfg = RuboCop::ConfigLoader.default_configuration[cop_name]
|
56
56
|
return unless default_cfg
|
57
57
|
|
58
|
-
params = default_cfg.keys -
|
58
|
+
params = default_cfg.keys -
|
59
|
+
%w(Description StyleGuide Reference Enabled) -
|
59
60
|
cfg.keys
|
60
61
|
return if params.empty?
|
61
62
|
|
@@ -21,7 +21,7 @@ module RuboCop
|
|
21
21
|
'disabled' => DisabledLinesFormatter
|
22
22
|
}
|
23
23
|
|
24
|
-
FORMATTER_APIS = [:started, :
|
24
|
+
FORMATTER_APIS = [:started, :finished]
|
25
25
|
|
26
26
|
FORMATTER_APIS.each do |method_name|
|
27
27
|
define_method(method_name) do |*args|
|
@@ -29,6 +29,29 @@ module RuboCop
|
|
29
29
|
end
|
30
30
|
end
|
31
31
|
|
32
|
+
def file_started(file, options)
|
33
|
+
@cop_disabled_line_ranges ||= {}
|
34
|
+
@cop_disabled_line_ranges[file] = options[:cop_disabled_line_ranges]
|
35
|
+
@comments ||= {}
|
36
|
+
@comments[file] = options[:comments]
|
37
|
+
@excepted_cops = options[:excepted_cops] || []
|
38
|
+
@only_cops = options[:only_cops] || []
|
39
|
+
each { |f| f.file_started(file, options) }
|
40
|
+
end
|
41
|
+
|
42
|
+
def file_finished(file, offenses)
|
43
|
+
if @cop_disabled_line_ranges[file].any? &&
|
44
|
+
# Don't check unneeded disable if --only or --except option is
|
45
|
+
# given, because these options override configuration.
|
46
|
+
@excepted_cops.empty? && @only_cops.empty?
|
47
|
+
cop = Cop::Lint::UnneededDisable.new
|
48
|
+
cop.check(file, offenses, @cop_disabled_line_ranges, @comments)
|
49
|
+
offenses += cop.offenses
|
50
|
+
end
|
51
|
+
offenses = offenses.sort.reject(&:disabled?)
|
52
|
+
each { |f| f.file_finished(file, offenses) }
|
53
|
+
end
|
54
|
+
|
32
55
|
def add_formatter(formatter_type, output_path = nil)
|
33
56
|
formatter_class = case formatter_type
|
34
57
|
when Class
|
data/lib/rubocop/options.rb
CHANGED
@@ -104,6 +104,10 @@ module RuboCop
|
|
104
104
|
end
|
105
105
|
|
106
106
|
def validate_compatibility
|
107
|
+
if @options.key?(:only) &&
|
108
|
+
(@options[:only] & %w(Lint/UnneededDisable UnneededDisable)).any?
|
109
|
+
fail ArgumentError, 'Lint/UnneededDisable can not be used with --only.'
|
110
|
+
end
|
107
111
|
return unless (incompat = @options.keys & EXITING_OPTIONS).size > 1
|
108
112
|
fail ArgumentError, "Incompatible cli options: #{incompat.inspect}"
|
109
113
|
end
|
@@ -13,7 +13,10 @@ module RuboCop
|
|
13
13
|
:parser_error, :raw_source
|
14
14
|
|
15
15
|
def self.from_file(path)
|
16
|
-
|
16
|
+
file = File.read(path)
|
17
|
+
new(file, path)
|
18
|
+
rescue
|
19
|
+
abort("#{Rainbow('rubocop: No such file or directory').red} -- #{path}")
|
17
20
|
end
|
18
21
|
|
19
22
|
def initialize(source, path = nil)
|
data/lib/rubocop/runner.rb
CHANGED
@@ -66,8 +66,14 @@ module RuboCop
|
|
66
66
|
puts "Scanning #{file}" if @options[:debug]
|
67
67
|
|
68
68
|
processed_source = ProcessedSource.from_file(file)
|
69
|
+
file_info = {
|
70
|
+
cop_disabled_line_ranges: processed_source.disabled_line_ranges,
|
71
|
+
comments: processed_source.comments,
|
72
|
+
only_cops: @options[:only],
|
73
|
+
excepted_cops: @options[:except]
|
74
|
+
}
|
69
75
|
|
70
|
-
formatter_set.file_started(file, file_info
|
76
|
+
formatter_set.file_started(file, file_info)
|
71
77
|
|
72
78
|
offenses = do_inspection_loop(file, processed_source)
|
73
79
|
|
@@ -190,8 +196,11 @@ module RuboCop
|
|
190
196
|
|
191
197
|
def considered_failure?(offense)
|
192
198
|
# For :autocorrect level, any offense - corrected or not - is a failure.
|
193
|
-
@options[:fail_level] == :autocorrect
|
194
|
-
|
199
|
+
return true if @options[:fail_level] == :autocorrect
|
200
|
+
|
201
|
+
return false if offense.disabled?
|
202
|
+
|
203
|
+
!offense.corrected? && offense.severity >= minimum_severity_to_fail
|
195
204
|
end
|
196
205
|
|
197
206
|
def minimum_severity_to_fail
|
@@ -200,9 +209,5 @@ module RuboCop
|
|
200
209
|
RuboCop::Cop::Severity.new(name)
|
201
210
|
end
|
202
211
|
end
|
203
|
-
|
204
|
-
def file_info(processed_source)
|
205
|
-
{ cop_disabled_line_ranges: processed_source.disabled_line_ranges }
|
206
|
-
end
|
207
212
|
end
|
208
213
|
end
|
@@ -88,16 +88,16 @@ module RuboCop
|
|
88
88
|
def find_files(base_dir, flags)
|
89
89
|
wanted_toplevel_dirs = toplevel_dirs(base_dir, flags) -
|
90
90
|
excluded_dirs(base_dir)
|
91
|
-
wanted_toplevel_dirs.map! { |dir| dir
|
91
|
+
wanted_toplevel_dirs.map! { |dir| dir << '/**/*' }
|
92
92
|
|
93
93
|
pattern = if wanted_toplevel_dirs.empty?
|
94
94
|
# We need this special case to avoid creating the pattern
|
95
95
|
# /**/* which searches the entire file system.
|
96
|
-
"#{base_dir}/**/*"
|
96
|
+
["#{base_dir}/**/*"]
|
97
97
|
else
|
98
98
|
# Search the non-excluded top directories, but also add files
|
99
99
|
# on the top level, which would otherwise not be found.
|
100
|
-
"
|
100
|
+
wanted_toplevel_dirs.unshift("#{base_dir}/*")
|
101
101
|
end
|
102
102
|
Dir.glob(pattern, flags).select { |path| FileTest.file?(path) }
|
103
103
|
end
|
data/lib/rubocop/version.rb
CHANGED
data/relnotes/v0.32.0.md
ADDED
@@ -0,0 +1,139 @@
|
|
1
|
+
### New features
|
2
|
+
|
3
|
+
* Adjust behavior of `TrailingComma` cop to account for multi-line hashes nested within method calls. ([@panthomakos][])
|
4
|
+
* [#1719](https://github.com/bbatsov/rubocop/pull/1719): Display an error and abort the program if input file can't be found. ([@matugm][])
|
5
|
+
* New cop `SpaceInsideStringInterpolation` checks for spaces within string interpolations. ([@glasnt][])
|
6
|
+
* New cop `NestedMethodDefinition` checks for method definitions inside other methods. ([@ojab][])
|
7
|
+
* `LiteralInInterpolation` cop does auto-correction. ([@tmr08c][])
|
8
|
+
* [#1865](https://github.com/bbatsov/rubocop/issues/1865): New cop `Lint/UnneededDisable` checks for `rubocop:disable` comments that can be removed. ([@jonas054][])
|
9
|
+
* `EmptyElse` cop does auto-correction. ([@lumeet][])
|
10
|
+
* Show reference links when displaying style guide links. ([@rrosenblum][])
|
11
|
+
* `Debugger` cop now checks for the Capybara debug method `save_screenshot`. ([@crazydog115][])
|
12
|
+
* [#1282](https://github.com/bbatsov/rubocop/issues/1282): `CaseIndentation` cop does auto-correction. ([@lumeet][])
|
13
|
+
* [#1928](https://github.com/bbatsov/rubocop/issues/1928): Do auto-correction one offense at a time (rather than one cop at a time) if there are tabs in the code. ([@jonas054][])
|
14
|
+
|
15
|
+
### Changes
|
16
|
+
|
17
|
+
* Prefer `SpaceInsideBlockBraces` to `SpaceBeforeSemicolon` and `SpaceAfterSemicolon` to avoid an infinite loop when auto-correcting. ([@lumeet][])
|
18
|
+
* [#1873](https://github.com/bbatsov/rubocop/issues/1873): Move `ParallelAssignment` cop from Performance to Style. ([@rrosenblum][])
|
19
|
+
* Add `getlocal` to acceptable methods of `Rails/TimeZone`. ([@ojab][])
|
20
|
+
* [#1851](https://github.com/bbatsov/rubocop/issues/1851), [#1948](https://github.com/bbatsov/rubocop/issues/1948): Change offense message for `ClassLength` and `ModuleLength` to match that of `MethodLength`. ([@bquorning][])
|
21
|
+
|
22
|
+
### Bugs fixed
|
23
|
+
|
24
|
+
* Don't count required keyword args when specifying `CountKeywordArgs: false` for `ParameterLists`. ([@sumeet][])
|
25
|
+
* [#1879](https://github.com/bbatsov/rubocop/issues/1879): Avoid auto-correcting hash with trailing comma into invalid code in `BracesAroundHashParameters`. ([@jonas054][])
|
26
|
+
* [#1868](https://github.com/bbatsov/rubocop/issues/1868): Do not register an offense in `Performance/Count` when `select` is called with symbols or strings as the parameters. ([@rrosenblum][])
|
27
|
+
* `Sample` rewritten to properly handle shuffle randomness source, first/last params and non-literal ranges. ([@chastell][])
|
28
|
+
* [#1873](https://github.com/bbatsov/rubocop/issues/1873): Modify `ParallelAssignment` to properly autocorrect when the assignment is protected by a modifier statement. ([@rrosenblum][])
|
29
|
+
* Configure `ParallelAssignment` to work with non-standard `IndentationWidths`. ([@rrosenblum][])
|
30
|
+
* [#1899](https://github.com/bbatsov/rubocop/issues/1899): Be careful about comments when auto-correcting in `BracesAroundHashParameters`. ([@jonas054][])
|
31
|
+
* [#1897](https://github.com/bbatsov/rubocop/issues/1897): Don't report that semicolon separated statements can be converted to modifier form in `IfUnlessModifier` (and don't auto-correct them). ([@jonas054][])
|
32
|
+
* [#1644](https://github.com/bbatsov/rubocop/issues/1644): Don't search the entire file system when a folder is named `,` (fix for jruby and rbx). ([@rrosenblum][])
|
33
|
+
* [#1803](https://github.com/bbatsov/rubocop/issues/1803): Don't warn for `return` from `lambda` block in `NonLocalExitFromIterator`. ([@ypresto][])
|
34
|
+
* [#1905](https://github.com/bbatsov/rubocop/issues/1905): Ignore sparse and trailing comments in `Style/Documentation`. ([@RGBD][])
|
35
|
+
* [#1923](https://github.com/bbatsov/rubocop/issues/1923): Handle properly `for` without body in `Style/Next`. ([@bbatsov][])
|
36
|
+
* [#1901](https://github.com/bbatsov/rubocop/issues/1901): Do not auto correct comments that are missing a note. ([@rrosenblum][])
|
37
|
+
* [#1926](https://github.com/bbatsov/rubocop/issues/1926): Fix crash in `Style/AlignHash` when correcting a hash with a splat in it. ([@rrosenblum][])
|
38
|
+
* [#1935](https://github.com/bbatsov/rubocop/issues/1935): Allow `Symbol#to_proc` blocks in Performance/Size. ([@m1foley][])
|
39
|
+
|
40
|
+
[@bbatsov]: https://github.com/bbatsov
|
41
|
+
[@jonas054]: https://github.com/jonas054
|
42
|
+
[@yujinakayama]: https://github.com/yujinakayama
|
43
|
+
[@dblock]: https://github.com/dblock
|
44
|
+
[@nevir]: https://github.com/nevir
|
45
|
+
[@daviddavis]: https://github.com/daviddavis
|
46
|
+
[@sds]: https://github.com/sds
|
47
|
+
[@fancyremarker]: https://github.com/fancyremarker
|
48
|
+
[@sinisterchipmunk]: https://github.com/sinisterchipmunk
|
49
|
+
[@vonTronje]: https://github.com/vonTronje
|
50
|
+
[@agrimm]: https://github.com/agrimm
|
51
|
+
[@pmenglund]: https://github.com/pmenglund
|
52
|
+
[@chulkilee]: https://github.com/chulkilee
|
53
|
+
[@codez]: https://github.com/codez
|
54
|
+
[@emou]: https://github.com/emou
|
55
|
+
[@skanev]: http://github.com/skanev
|
56
|
+
[@claco]: http://github.com/claco
|
57
|
+
[@rifraf]: http://github.com/rifraf
|
58
|
+
[@scottmatthewman]: https://github.com/scottmatthewman
|
59
|
+
[@ma2gedev]: http://github.com/ma2gedev
|
60
|
+
[@jeremyolliver]: https://github.com/jeremyolliver
|
61
|
+
[@hannestyden]: https://github.com/hannestyden
|
62
|
+
[@geniou]: https://github.com/geniou
|
63
|
+
[@jkogara]: https://github.com/jkogara
|
64
|
+
[@tmorris-fiksu]: https://github.com/tmorris-fiksu
|
65
|
+
[@mockdeep]: https://github.com/mockdeep
|
66
|
+
[@hiroponz]: https://github.com/hiroponz
|
67
|
+
[@tamird]: https://github.com/tamird
|
68
|
+
[@fshowalter]: https://github.com/fshowalter
|
69
|
+
[@cschramm]: https://github.com/cschramm
|
70
|
+
[@bquorning]: https://github.com/bquorning
|
71
|
+
[@bcobb]: https://github.com/bcobb
|
72
|
+
[@irrationalfab]: https://github.com/irrationalfab
|
73
|
+
[@tommeier]: https://github.com/tommeier
|
74
|
+
[@sfeldon]: https://github.com/sfeldon
|
75
|
+
[@biinari]: https://github.com/biinari
|
76
|
+
[@barunio]: https://github.com/barunio
|
77
|
+
[@molawson]: https://github.com/molawson
|
78
|
+
[@wndhydrnt]: https://github.com/wndhydrnt
|
79
|
+
[@ggilder]: https://github.com/ggilder
|
80
|
+
[@salbertson]: https://github.com/salbertson
|
81
|
+
[@camilleldn]: https://github.com/camilleldn
|
82
|
+
[@mcls]: https://github.com/mcls
|
83
|
+
[@yous]: https://github.com/yous
|
84
|
+
[@vrthra]: https://github.com/vrthra
|
85
|
+
[@SkuliOskarsson]: https://github.com/SkuliOskarsson
|
86
|
+
[@jspanjers]: https://github.com/jspanjers
|
87
|
+
[@sch1zo]: https://github.com/sch1zo
|
88
|
+
[@smangelsdorf]: https://github.com/smangelsdorf
|
89
|
+
[@mvz]: https://github.com/mvz
|
90
|
+
[@jfelchner]: https://github.com/jfelchner
|
91
|
+
[@janraasch]: https://github.com/janraasch
|
92
|
+
[@jcarbo]: https://github.com/jcarbo
|
93
|
+
[@oneamtu]: https://github.com/oneamtu
|
94
|
+
[@toy]: https://github.com/toy
|
95
|
+
[@Koronen]: https://github.com/Koronen
|
96
|
+
[@blainesch]: https://github.com/blainesch
|
97
|
+
[@marxarelli]: https://github.com/marxarelli
|
98
|
+
[@katieschilling]: https://github.com/katieschilling
|
99
|
+
[@kakutani]: https://github.com/kakutani
|
100
|
+
[@rrosenblum]: https://github.com/rrosenblum
|
101
|
+
[@mattjmcnaughton]: https://github.com/mattjmcnaughton
|
102
|
+
[@huerlisi]: https://github.com/huerlisi
|
103
|
+
[@volkert]: https://github.com/volkert
|
104
|
+
[@lumeet]: https://github.com/lumeet
|
105
|
+
[@mmozuras]: https://github.com/mmozuras
|
106
|
+
[@d4rk5eed]: https://github.com/d4rk5eed
|
107
|
+
[@cshaffer]: https://github.com/cshaffer
|
108
|
+
[@eitoball]: https://github.com/eitoball
|
109
|
+
[@iainbeeston]: https://github.com/iainbeeston
|
110
|
+
[@pimterry]: https://github.com/pimterry
|
111
|
+
[@palkan]: https://github.com/palkan
|
112
|
+
[@jdoconnor]: https://github.com/jdoconnor
|
113
|
+
[@meganemura]: https://github.com/meganemura
|
114
|
+
[@zvkemp]: https://github.com/zvkemp
|
115
|
+
[@vassilevsky]: https://github.com/vassilevsky
|
116
|
+
[@gerry3]: https://github.com/gerry3
|
117
|
+
[@ypresto]: https://github.com/ypresto
|
118
|
+
[@clowder]: https://github.com/clowder
|
119
|
+
[@mudge]: https://github.com/mudge
|
120
|
+
[@mzp]: https://github.com/mzp
|
121
|
+
[@bankair]: https://github.com/bankair
|
122
|
+
[@crimsonknave]: https://github.com/crimsonknave
|
123
|
+
[@renuo]: https://github.com/renuo
|
124
|
+
[@sdeframond]: https://github.com/sdeframond
|
125
|
+
[@til]: https://github.com/til
|
126
|
+
[@carhartl]: https://github.com/carhartl
|
127
|
+
[@dylandavidson]: https://github.com/dylandavidson
|
128
|
+
[@tmr08c]: https://github.com/tmr08c
|
129
|
+
[@hbd225]: https://github.com/hbd225
|
130
|
+
[@l8nite]: https://github.com/l8nite
|
131
|
+
[@sumeet]: https://github.com/sumeet
|
132
|
+
[@ojab]: https://github.com/ojab
|
133
|
+
[@chastell]: https://github.com/chastell
|
134
|
+
[@glasnt]: https://github.com/glasnt
|
135
|
+
[@crazydog115]: https://github.com/crazydog115
|
136
|
+
[@RGBD]: https://github.com/RGBD
|
137
|
+
[@panthomakos]: https://github.com/panthomakos
|
138
|
+
[@matugm]: https://github.com/matugm
|
139
|
+
[@m1foley]: https://github.com/m1foley
|
data/rubocop.gemspec
CHANGED
@@ -39,12 +39,12 @@ Gem::Specification.new do |s|
|
|
39
39
|
s.summary = 'Automatic Ruby code style checking tool.'
|
40
40
|
|
41
41
|
s.add_runtime_dependency('rainbow', '>= 1.99.1', '< 3.0')
|
42
|
-
s.add_runtime_dependency('parser', '>= 2.2.2.
|
42
|
+
s.add_runtime_dependency('parser', '>= 2.2.2.5', '< 3.0')
|
43
43
|
s.add_runtime_dependency('powerpack', '~> 0.1')
|
44
44
|
s.add_runtime_dependency('astrolabe', '~> 1.3')
|
45
45
|
s.add_runtime_dependency('ruby-progressbar', '~> 1.4')
|
46
46
|
s.add_development_dependency('rake', '~> 10.1')
|
47
|
-
s.add_development_dependency('rspec', '~> 3.
|
47
|
+
s.add_development_dependency('rspec', '~> 3.2.0')
|
48
48
|
s.add_development_dependency('yard', '~> 0.8')
|
49
49
|
s.add_development_dependency('bundler', '~> 1.3')
|
50
50
|
s.add_development_dependency('simplecov', '~> 0.7')
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubocop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.32.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bozhidar Batsov
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2015-
|
13
|
+
date: 2015-06-06 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rainbow
|
@@ -38,7 +38,7 @@ dependencies:
|
|
38
38
|
requirements:
|
39
39
|
- - ">="
|
40
40
|
- !ruby/object:Gem::Version
|
41
|
-
version: 2.2.2.
|
41
|
+
version: 2.2.2.5
|
42
42
|
- - "<"
|
43
43
|
- !ruby/object:Gem::Version
|
44
44
|
version: '3.0'
|
@@ -48,7 +48,7 @@ dependencies:
|
|
48
48
|
requirements:
|
49
49
|
- - ">="
|
50
50
|
- !ruby/object:Gem::Version
|
51
|
-
version: 2.2.2.
|
51
|
+
version: 2.2.2.5
|
52
52
|
- - "<"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '3.0'
|
@@ -114,14 +114,14 @@ dependencies:
|
|
114
114
|
requirements:
|
115
115
|
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: 3.
|
117
|
+
version: 3.2.0
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
122
|
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version: 3.
|
124
|
+
version: 3.2.0
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: yard
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -220,6 +220,7 @@ files:
|
|
220
220
|
- lib/rubocop/cop/lint/literal_in_condition.rb
|
221
221
|
- lib/rubocop/cop/lint/literal_in_interpolation.rb
|
222
222
|
- lib/rubocop/cop/lint/loop.rb
|
223
|
+
- lib/rubocop/cop/lint/nested_method_definition.rb
|
223
224
|
- lib/rubocop/cop/lint/non_local_exit_from_iterator.rb
|
224
225
|
- lib/rubocop/cop/lint/parentheses_as_grouped_expression.rb
|
225
226
|
- lib/rubocop/cop/lint/require_parentheses.rb
|
@@ -229,6 +230,7 @@ files:
|
|
229
230
|
- lib/rubocop/cop/lint/string_conversion_in_interpolation.rb
|
230
231
|
- lib/rubocop/cop/lint/syntax.rb
|
231
232
|
- lib/rubocop/cop/lint/underscore_prefixed_variable_name.rb
|
233
|
+
- lib/rubocop/cop/lint/unneeded_disable.rb
|
232
234
|
- lib/rubocop/cop/lint/unreachable_code.rb
|
233
235
|
- lib/rubocop/cop/lint/unused_block_argument.rb
|
234
236
|
- lib/rubocop/cop/lint/unused_method_argument.rb
|
@@ -281,7 +283,6 @@ files:
|
|
281
283
|
- lib/rubocop/cop/performance/count.rb
|
282
284
|
- lib/rubocop/cop/performance/detect.rb
|
283
285
|
- lib/rubocop/cop/performance/flat_map.rb
|
284
|
-
- lib/rubocop/cop/performance/parallel_assignment.rb
|
285
286
|
- lib/rubocop/cop/performance/reverse_each.rb
|
286
287
|
- lib/rubocop/cop/performance/sample.rb
|
287
288
|
- lib/rubocop/cop/performance/size.rb
|
@@ -394,6 +395,7 @@ files:
|
|
394
395
|
- lib/rubocop/cop/style/numeric_literals.rb
|
395
396
|
- lib/rubocop/cop/style/one_line_conditional.rb
|
396
397
|
- lib/rubocop/cop/style/op_method.rb
|
398
|
+
- lib/rubocop/cop/style/parallel_assignment.rb
|
397
399
|
- lib/rubocop/cop/style/parentheses_around_condition.rb
|
398
400
|
- lib/rubocop/cop/style/percent_literal_delimiters.rb
|
399
401
|
- lib/rubocop/cop/style/percent_q_literals.rb
|
@@ -432,6 +434,7 @@ files:
|
|
432
434
|
- lib/rubocop/cop/style/space_inside_hash_literal_braces.rb
|
433
435
|
- lib/rubocop/cop/style/space_inside_parens.rb
|
434
436
|
- lib/rubocop/cop/style/space_inside_range_literal.rb
|
437
|
+
- lib/rubocop/cop/style/space_inside_string_interpolation.rb
|
435
438
|
- lib/rubocop/cop/style/special_global_vars.rb
|
436
439
|
- lib/rubocop/cop/style/string_literals.rb
|
437
440
|
- lib/rubocop/cop/style/string_literals_in_interpolation.rb
|
@@ -510,6 +513,7 @@ files:
|
|
510
513
|
- relnotes/v0.30.0.md
|
511
514
|
- relnotes/v0.30.1.md
|
512
515
|
- relnotes/v0.31.0.md
|
516
|
+
- relnotes/v0.32.0.md
|
513
517
|
- rubocop.gemspec
|
514
518
|
homepage: http://github.com/bbatsov/rubocop
|
515
519
|
licenses:
|
@@ -531,7 +535,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
531
535
|
version: '0'
|
532
536
|
requirements: []
|
533
537
|
rubyforge_project:
|
534
|
-
rubygems_version: 2.
|
538
|
+
rubygems_version: 2.4.5
|
535
539
|
signing_key:
|
536
540
|
specification_version: 4
|
537
541
|
summary: Automatic Ruby code style checking tool.
|