Skip to content

Commit 4ef4d31

Browse files
committed
(PUP-11993) Exclude portage.rb from Lint/RedundantSplatExpansion
This commit excludes lib/puppet/provider/package/portage.rb from the Lint/RedundantSplatExpansion cop because I am unsure of how those changes will impact the code. This commit also undoes the changes made in portage.rb for that cop.
1 parent 978296e commit 4ef4d31

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

.rubocop_todo.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,12 @@ Lint/RedundantDirGlobSort: # new in 1.8
128128
Lint/RedundantRegexpQuantifiers: # new in 1.53
129129
Enabled: false
130130

131+
# Unsure how the changes in portage.rb from Lint/RedundantSplatExpansion impact
132+
# the code
133+
Lint/RedundantSplatExpansion:
134+
Exclude:
135+
- 'lib/puppet/provider/package/portage.rb'
136+
131137
Lint/RefinementImportMethods: # new in 1.27
132138
Enabled: false
133139

lib/puppet/provider/package/portage.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ def qatom
121121
else
122122
search = '=' + @resource[:name] + '-' + "#{should}"
123123
end
124-
search_output = qatom_bin(search, '--format', output_format)
124+
search_output = qatom_bin(*[search, '--format', output_format])
125125
# verify if the search found anything
126126
match = result_format.match(search_output)
127127
if match
@@ -155,7 +155,7 @@ def qatom_result_fields
155155
end
156156

157157
def self.get_sets
158-
@sets ||= @sets = emerge('--list-sets')
158+
@sets ||= @sets = emerge(*['--list-sets'])
159159
end
160160

161161
def query

0 commit comments

Comments
 (0)