update arg names in docs and signature
This commit is contained in:
parent
dff3fc9d2f
commit
b2d94dc897
@ -1625,18 +1625,19 @@ class Formula
|
|||||||
end
|
end
|
||||||
private :extract_macho_slice_from
|
private :extract_macho_slice_from
|
||||||
|
|
||||||
# Generate shell completions for a formula for bash, zsh, and fish, using the formula's binary.
|
# Generate shell completions for a formula for bash, zsh, and fish, using the formula's executable.
|
||||||
#
|
#
|
||||||
# @param base_name [String] the base name of the generated completion script. Defaults to the formula name.
|
# @param base_name [String] the base name of the generated completion script. Defaults to the formula name.
|
||||||
# @param shells [Array<Symbol>] the shells to generate completion scripts for. Defaults to `[:bash, :zsh, :fish]`.
|
# @param shells [Array<Symbol>] the shells to generate completion scripts for. Defaults to `[:bash, :zsh, :fish]`.
|
||||||
# @param binary [Pathname] the binary to use for generating the completion scripts. Defaults to the binary with the
|
# @param executable [Pathname] the executable to use for generating the completion scripts. Defaults to the
|
||||||
# name of the formula.
|
# executable with the name of the formula.
|
||||||
# @param cmd [String] the command to pass to the `binary`. Defaults to 'completion'.
|
# @param cmd [String] the command to pass to the `binary`. Defaults to 'completion'.
|
||||||
# @param shell_as_flag [Boolean] specify if `shells` should each be passed as flags to the `binary`.
|
# @param shell_parameter_format [String]/[Symbol] specify how `shells` should each be passed
|
||||||
# Defaults to `false`.
|
# to the `executable`. Takes either a String representing a prefix, or one of [:flag, :arg, :none].
|
||||||
|
# Defaults to plainly passing the shell.
|
||||||
sig {
|
sig {
|
||||||
params(base_name: String, shells: T::Array[Symbol], binary: Pathname, cmd: String,
|
params(base_name: String, shells: T::Array[Symbol], executable: Pathname, cmd: String,
|
||||||
shell_prefix: T.nilable(T.any(Symbol, String))).void
|
shell_parameter_format: T.nilable(T.any(Symbol, String))).void
|
||||||
}
|
}
|
||||||
def generate_completions_from_executable(base_name: name,
|
def generate_completions_from_executable(base_name: name,
|
||||||
shells: [:bash, :zsh, :fish],
|
shells: [:bash, :zsh, :fish],
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user