From 663a7cd563c6d10effc9aba57626e16b54ace74a Mon Sep 17 00:00:00 2001 From: Florian Schwab Date: Sat, 9 Jun 2018 18:45:58 +0200 Subject: [PATCH] fix rubocop warnings --- .rubocop.yml | 3 +++ Rakefile | 2 +- capistrano-rails-console.gemspec | 3 ++- lib/capistrano/rails/console.rb | 2 +- lib/capistrano/rails/console/version.rb | 2 +- 5 files changed, 8 insertions(+), 4 deletions(-) create mode 100644 .rubocop.yml diff --git a/.rubocop.yml b/.rubocop.yml new file mode 100644 index 0000000..c33d73d --- /dev/null +++ b/.rubocop.yml @@ -0,0 +1,3 @@ +Naming/FileName: + Exclude: + - 'lib/capistrano-rails-console.rb' diff --git a/Rakefile b/Rakefile index 2995527..c702cfc 100644 --- a/Rakefile +++ b/Rakefile @@ -1 +1 @@ -require "bundler/gem_tasks" +require 'bundler/gem_tasks' diff --git a/capistrano-rails-console.gemspec b/capistrano-rails-console.gemspec index f662b81..b94c4c1 100644 --- a/capistrano-rails-console.gemspec +++ b/capistrano-rails-console.gemspec @@ -1,6 +1,7 @@ lib = File.expand_path('lib', __dir__) $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) require 'capistrano/rails/console/version' +require 'english' Gem::Specification.new do |spec| spec.name = 'capistrano-rails-console' @@ -12,7 +13,7 @@ Gem::Specification.new do |spec| spec.homepage = 'https://gitlab.com/ydkn/capistrano-rails-console' spec.license = 'MIT' - spec.files = `git ls-files`.split($/) + spec.files = `git ls-files`.split($RS) spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) } spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) spec.require_paths = ['lib'] diff --git a/lib/capistrano/rails/console.rb b/lib/capistrano/rails/console.rb index 29664ab..fc319fc 100644 --- a/lib/capistrano/rails/console.rb +++ b/lib/capistrano/rails/console.rb @@ -1,4 +1,4 @@ require 'sshkit/interactive' require 'capistrano/rails/console/version' -load File.expand_path('../console/tasks.cap', __FILE__) +load File.expand_path('console/tasks.cap', __dir__) diff --git a/lib/capistrano/rails/console/version.rb b/lib/capistrano/rails/console/version.rb index ac31e28..71ef6d5 100644 --- a/lib/capistrano/rails/console/version.rb +++ b/lib/capistrano/rails/console/version.rb @@ -5,7 +5,7 @@ module Capistrano # Console module Console # Gem version - VERSION = '2.3.0' + VERSION = '2.3.0'.freeze end end end