mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-11-15 01:28:17 -07:00
fix: correct list usage in asdf.nu
After installing asdf.nu in my nushell config, running `asdf plugin list` gives me the following error:
❯ asdf plugin list
Error: nu:🐚:cannot_pass_list_to_external
× Lists are not automatically spread when calling external commands
╭─[/opt/asdf-vm/asdf.nu:110:27]
109 │
110 │ ^asdf plugin list $flags | lines | parse -r $template | str trim
· ───┬──
· ╰── Spread operator (...) is necessary to spread lists
111 │ }
╰────
help: Either convert the list to a string or use the spread operator, like so: ...$flags
This change fixes the error.
This commit is contained in:
parent
ccdd47df9b
commit
bcd33c861f
2
asdf.nu
2
asdf.nu
@ -107,7 +107,7 @@ module asdf {
|
|||||||
|
|
||||||
let flags = ($params | where enabled | get --ignore-errors flag | default '' )
|
let flags = ($params | where enabled | get --ignore-errors flag | default '' )
|
||||||
|
|
||||||
^asdf plugin list $flags | lines | parse -r $template | str trim
|
^asdf plugin list ...$flags | lines | parse -r $template | str trim
|
||||||
}
|
}
|
||||||
|
|
||||||
# list all available plugins
|
# list all available plugins
|
||||||
|
Loading…
Reference in New Issue
Block a user