mirror of
https://github.com/wavetermdev/homebrew-cask.git
synced 2026-08-05 13:43:24 -07:00
rubocop: In-line disables of Style/GlobalVars offenses
- We're working to remove the global `Excludes:` from RuboCop configuration in `Homebrew/brew` (see issue 14685 over there). - This file in Cask was the only place where global vars weren't already in-line disabled. So, to be able to clean up the configuration stanza in Homebrew/brew PR 14878, I've added some.
This commit is contained in:
@@ -370,7 +370,7 @@ def warnings
|
||||
end
|
||||
|
||||
def report
|
||||
puts "Proposed Simplified App name: #{simplified_app_name}" if $debug
|
||||
puts "Proposed Simplified App name: #{simplified_app_name}" if $debug # rubocop:disable Style/GlobalVars
|
||||
puts "Proposed token: #{cask_token}"
|
||||
puts "Proposed file name: #{cask_file_name}"
|
||||
puts "Cask Header Line: cask \"#{cask_token}\" do"
|
||||
@@ -402,7 +402,7 @@ if /^-+h(elp)?$/i.match?(ARGV.first)
|
||||
end
|
||||
|
||||
if /^-+debug?$/i.match?(ARGV.first)
|
||||
$debug = 1
|
||||
$debug = 1 # rubocop:disable Style/GlobalVars
|
||||
ARGV.shift
|
||||
end
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ def process_args
|
||||
puts usage
|
||||
exit 0
|
||||
elsif ARGV.length == 1
|
||||
$app_path = ARGV.first
|
||||
$app_path = ARGV.first # rubocop:disable Style/GlobalVars
|
||||
else
|
||||
puts usage
|
||||
exit 1
|
||||
@@ -63,4 +63,4 @@ end
|
||||
###
|
||||
|
||||
process_args
|
||||
list_login_items_for_app $app_path
|
||||
list_login_items_for_app $app_path # rubocop:disable Style/GlobalVars
|
||||
|
||||
@@ -17,6 +17,7 @@ require "io/console"
|
||||
### globals
|
||||
###
|
||||
|
||||
# rubocop:disable Style/GlobalVars
|
||||
$opt_test = nil
|
||||
$COLUMNS = IO.console.winsize.last
|
||||
|
||||
@@ -120,3 +121,4 @@ if $opt_test
|
||||
else
|
||||
report_apps
|
||||
end
|
||||
# rubocop:enable Style/GlobalVars
|
||||
|
||||
Reference in New Issue
Block a user