asdf icon indicating copy to clipboard operation
asdf copied to clipboard

chore: `--all` flag missing from completions for `asdf latest` command

Open acidghost opened this issue 3 years ago • 1 comments

Describe the Bug

The completions for the --all flag to the latest command are missing.

Steps to Reproduce

Type asdf latest and press <TAB>.

Expected Behaviour

Show --all flag besides installed plugins.

Actual Behaviour

Only shows plugins.

Environment

SHELL:
zsh 5.8 (x86_64-apple-darwin21.0)

ASDF VERSION:
v0.10.0

ASDF ENVIRONMENT VARIABLES:
ASDF_DIR=/Users/acidghost/.dotfiles/asdf-vm

ASDF INSTALLED PLUGINS:
golang                       https://github.com/kennyp/asdf-golang.git master cc8bc47
julia                        https://github.com/rkyleg/asdf-julia.git master 1788f0f
nodejs                       https://github.com/asdf-vm/asdf-nodejs.git master f9957f3
perl                         https://github.com/ouest/asdf-perl.git master 1d6d39c
python                       https://github.com/danhper/asdf-python.git master 57a4d72
ruby                         https://github.com/asdf-vm/asdf-ruby.git master 3179071

asdf plugins affected (if relevant)

No response

acidghost avatar Apr 18 '22 10:04 acidghost

I changed this from a bug as completions are opt-in and not critical to the execution of the core tool. Completions are something we rely on the community to contribute updates to.

I do not use completions or know the state of what is up to date or not. Looking at the fish completions it appears we would need to add

complete -f -c asdf -n '__fish_asdf_using_command latest; and __fish_asdf_arg_number 2' -a --all'

below the following line

https://github.com/asdf-vm/asdf/blob/e1fd8ad970613b1d9d97d6af6c9890c436226ba5/completions/asdf.fish#L103

Not sure about other completions though, PRs weclome!

jthegedus avatar Jul 17 '22 08:07 jthegedus