generate_completions: fix shell_parameter_format: :none

This commit is contained in:
Max Eisner 2022-09-02 15:40:24 +02:00
parent e689cc07d9
commit b41dd8c729
No known key found for this signature in database
GPG Key ID: 4BF122C22879F0C8

View File

@ -1745,14 +1745,14 @@ class Formula
elsif shell_parameter_format == :arg
"--shell=#{shell}"
elsif shell_parameter_format == :none
""
nil
else
"#{shell_parameter_format}#{shell}"
end
popen_read_args = %w[]
popen_read_args << commands
popen_read_args << shell_parameter
popen_read_args << shell_parameter unless shell_parameter.nil?
popen_read_args.flatten!
script_path.dirname.mkpath