Skip to content

Commit 4459669

Browse files
authored
Merge pull request #1896 from vitorgalvao/cleanups-internal-stanzas
Cask: cleanups internal stanzas
2 parents e12c1db + a64e283 commit 4459669

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

Library/Homebrew/cask/lib/hbc/cli/internal_dump.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def self.dump_casks(*cask_tokens)
2727
end
2828

2929
def self.help
30-
"Dump the given Cask in YAML format"
30+
"dump the given Cask in YAML format"
3131
end
3232
end
3333
end

Library/Homebrew/cask/lib/hbc/cli/internal_help.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def self.help_for(klass)
1616
end
1717

1818
def self.help
19-
"Print help strings for unstable internal-use commands"
19+
"print help strings for unstable internal-use commands"
2020
end
2121
end
2222
end

Library/Homebrew/cask/lib/hbc/cli/internal_stanza.rb

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -50,12 +50,12 @@ class InternalStanza < InternalUseBase
5050
:uninstall_postflight,
5151
]
5252

53-
def self.run(*arguments)
54-
table = arguments.include? "--table"
55-
quiet = arguments.include? "--quiet"
56-
format = :to_yaml if arguments.include? "--yaml"
57-
format = :inspect if arguments.include? "--inspect"
58-
cask_tokens = arguments.reject { |arg| arg.chars.first == "-" }
53+
def self.run(*args)
54+
table = args.include? "--table"
55+
quiet = args.include? "--quiet"
56+
format = :to_yaml if args.include? "--yaml"
57+
format = :inspect if args.include? "--inspect"
58+
cask_tokens = cask_tokens_from(args)
5959
stanza = cask_tokens.shift.to_sym
6060
cask_tokens = Hbc.all_tokens if cask_tokens.empty?
6161

@@ -125,7 +125,7 @@ def self.print_stanzas(stanza, format = nil, table = nil, quiet = nil, *cask_tok
125125
end
126126

127127
def self.help
128-
"Extract and render a specific stanza for the given Casks"
128+
"extract and render a specific stanza for the given Casks"
129129
end
130130
end
131131
end

0 commit comments

Comments
 (0)