Open simonpercivall opened 1 month ago
Something like this seems to work, instead of the _arguments
:
_arguments -C "*: :->args"
case $state in
(args)
case $line[1] in
(run)
_arguments "*: :($(usage complete-word --shell zsh -s "$spec" -- "${words[@]}" ))"
;;
(*)
_arguments "*: :(($(usage complete-word --shell zsh -s "$spec" -- "${words[@]}" )))"
;;
esac
esac
mise 2024.5.28 if it matters zsh 5.9
The zsh
_arguments
completion helper, when given an action in double parentheses, accepts completions on the formatword:description
. With mise tasks using:
for grouping, this breaks completion.If
_mise
is modified to use single parentheses for_arguments
, it works (but, of course, breaks all the other completions that do have descriptions).Example:
usage
correctly completes the tasks:zsh
autocomplete, however, gives only:and autocompletes only "lint".