From 5f8e7c2cc98a6288f9f85a2f5e8d2159a7f3bee4 Mon Sep 17 00:00:00 2001 From: William Johnston Date: Tue, 1 Mar 2016 09:36:05 -0600 Subject: [PATCH] Enable SpecialGlobalVars cop --- .rubocop.yml | 2 -- capistrano.gemspec | 2 +- features/support/vagrant_helpers.rb | 2 +- spec/support/test_app.rb | 2 +- 4 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index 6e1f8d25..764f5944 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -61,8 +61,6 @@ Style/WhileUntilModifier: Enabled: false Style/RescueModifier: Enabled: false -Style/SpecialGlobalVars: - Enabled: false Style/ModuleFunction: Enabled: false Style/DotPosition: diff --git a/capistrano.gemspec b/capistrano.gemspec index cda85487..4ac404d0 100644 --- a/capistrano.gemspec +++ b/capistrano.gemspec @@ -12,7 +12,7 @@ Gem::Specification.new do |gem| gem.summary = "Capistrano - Welcome to easy deployment with Ruby over SSH" gem.homepage = "http://capistranorb.com/" - gem.files = `git ls-files`.split($/) + gem.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR) gem.executables = %w(cap capify) gem.test_files = gem.files.grep(%r{^(test|spec|features)/}) gem.require_paths = ["lib"] diff --git a/features/support/vagrant_helpers.rb b/features/support/vagrant_helpers.rb index f2474c17..c9f276f6 100644 --- a/features/support/vagrant_helpers.rb +++ b/features/support/vagrant_helpers.rb @@ -19,7 +19,7 @@ module VagrantHelpers puts "[vagrant] #{line}" end end - $? + $CHILD_STATUS end def run_vagrant_command(command) diff --git a/spec/support/test_app.rb b/spec/support/test_app.rb index 894c0893..0770825c 100644 --- a/spec/support/test_app.rb +++ b/spec/support/test_app.rb @@ -91,7 +91,7 @@ module TestApp Dir.chdir(test_app_path) do output = %x[#{command}] end - [$?.success?, output] + [$CHILD_STATUS.success?, output] end def stage