Skip to content

Commit

Permalink
RuboCop 0.50.0; lints
Browse files Browse the repository at this point in the history
  • Loading branch information
olleolleolle committed Sep 18, 2017
1 parent 7f12a55 commit 9662c93
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 7 deletions.
9 changes: 7 additions & 2 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Metrics/ClassLength:
Metrics/MethodLength:
Enabled: false

Style/FileName:
Naming/FileName:
Exclude:
- 'bin/git-generate-changelog'

Expand All @@ -36,7 +36,7 @@ Metrics/AbcSize:
Enabled: false

# Offense count: 1
Style/AccessorMethodName:
Naming/AccessorMethodName:
Enabled: false

# Offense count: 10
Expand Down Expand Up @@ -75,3 +75,8 @@ Style/SafeNavigation:
Metrics/BlockLength:
Exclude:
- 'spec/**/*'

# Re-enable when merged; https://github.com/bbatsov/rubocop/pull/4756
Lint/InterpolationCheck:
Enabled: false

2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ group :development, :test do
gem "bundler"
gem "overcommit", ">= 0.31"
gem "rake"
gem "rubocop", ">= 0.43"
gem "rubocop", ">= 0.50"
end

group :development do
Expand Down
1 change: 0 additions & 1 deletion github_changelog_generator.gemspec
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# coding: utf-8
# frozen_string_literal: true

lib = File.expand_path("../lib", __FILE__)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def set_date_from_event(event, issue)
issue["actual_date"] = commit["commit"]["author"]["date"]

# issue['actual_date'] = commit['author']['date']
rescue
rescue StandardError
puts "Warning: Can't fetch commit #{event['commit_id']}. It is probably referenced from another repo."
issue["actual_date"] = issue["closed_at"]
end
Expand Down
2 changes: 1 addition & 1 deletion lib/github_changelog_generator/parser.rb
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ def self.user_project_from_option(arg0, arg1, github_site)

begin
param = match[2].nil?
rescue
rescue StandardError
puts "Can't detect user and name from first parameter: '#{arg0}' -> exit'"
return
end
Expand Down
2 changes: 1 addition & 1 deletion lib/github_changelog_generator/parser_file.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def parse_line!(line, line_number)
return if non_configuration_line?(line)
option_name, value = extract_pair(line)
@options[option_key_for(option_name)] = convert_value(value, option_name)
rescue
rescue StandardError
raise ParserError, "Failed on line ##{line_number}: \"#{line.gsub(/[\n\r]+/, '')}\""
end

Expand Down

0 comments on commit 9662c93

Please sign in to comment.