Skip to content

Commit

Permalink
Upd styles for new Rubocop
Browse files Browse the repository at this point in the history
  • Loading branch information
palkan committed Mar 16, 2018
1 parent 71a2f8c commit a31bd89
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ AllCops:
Naming/AccessorMethodName:
Enabled: false

Naming/UncommunicativeMethodParamName:
Enabled: false

Style/TrivialAccessors:
Enabled: false

Expand Down
2 changes: 1 addition & 1 deletion lib/generators/logidze/install/install_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module Generators
class InstallGenerator < ::Rails::Generators::Base # :nodoc:
include Rails::Generators::Migration

source_root File.expand_path('../templates', __FILE__)
source_root File.expand_path('templates', __dir__)

class_option :update, type: :boolean, optional: true,
desc: "Define whether this is an update migration"
Expand Down
2 changes: 1 addition & 1 deletion lib/generators/logidze/model/model_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
module Logidze
module Generators
class ModelGenerator < ::ActiveRecord::Generators::Base # :nodoc:
source_root File.expand_path('../templates', __FILE__)
source_root File.expand_path('templates', __dir__)

class_option :limit, type: :numeric, optional: true, desc: "Specify history size limit"

Expand Down
2 changes: 1 addition & 1 deletion spec/generators/install_generator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require 'generators/logidze/install/install_generator'

describe Logidze::Generators::InstallGenerator, type: :generator do
destination File.expand_path("../../../tmp", __FILE__)
destination File.expand_path('../../tmp', __dir__)

let(:args) { [] }

Expand Down
2 changes: 1 addition & 1 deletion spec/generators/model_generator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
require 'generators/logidze/model/model_generator'

describe Logidze::Generators::ModelGenerator, type: :generator do
destination File.expand_path("../../../tmp", __FILE__)
destination File.expand_path('../../tmp', __dir__)

before do
prepare_destination
Expand Down
2 changes: 1 addition & 1 deletion spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
SimpleCov.start
end

require File.expand_path("../dummy/config/environment", __FILE__)
require File.expand_path('dummy/config/environment', __dir__)

Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }

Expand Down

0 comments on commit a31bd89

Please sign in to comment.