Rubocop v0.10.0 Release Notes
Release Date: 2013-07-17 // almost 11 years ago-
๐ New features
- ๐ New cop
RedundantReturn
tracks redundantreturn
s in method bodies. - ๐ New cop
RedundantBegin
tracks redundantbegin
blocks in method definitions. - ๐ New cop
RedundantSelf
tracks redundant uses ofself
. - ๐ New cop
EmptyEnsure
tracks emptyensure
blocks. - ๐ New cop
CommentAnnotation
tracks formatting of annotation comments such as TODO. - โ Added custom rake task.
- ๐ New formatter
FileListFormatter
outputs just a list of files with offences in them (related to #357).
๐ Changes
TrivialAccessors
now has anExactNameMatch
config option (related to #308).TrivialAccessors
now has anExcludePredicates
config option (related to #326).- ๐ Cops don't inherit from
Parser::AST::Rewriter
anymore. All 3rd party Cops should remove the call tosuper
in their callbacks. If you implement your own processing you need to define the#investigate
method instead of#inspect
. Refer to the documentation ofCop::Commissioner
andCop::Cop
classes for more information. EndAlignment
cop split intoEndAlignment
andBlockAlignment
cops.
๐ Bugs fixed
- #288: Work with absolute Excludes paths internally (2nd fix for this issue).
TrivialAccessors
now detects class attributes as well as instance attributes.- #338: Fix end alignment of blocks in chained assignments.
- #345: Add
$SAFE
to the list of built-in global variables. - ๐ #340: Override config parameters rather than merging them.
- #349: Fix false positive for
CharacterLiteral
(%w(?)
). - ๐ #346: Support method chains for block end alignment checks.
- ๐ #350: Support line breaks between variables on left hand side for block end alignment checks.
- #356: Allow safe assignment in
ParenthesesAroundCondition
.
Misc
- ๐ Improved performance on Ruby 1.9 by about 20%.
- ๐ Improved overall performance by about 35%.
- ๐ New cop