[Fish completion] Enrich description for container/image candidates #1623
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
- What I did
For container/image candidates of fish completion, enriched description to include more info rather than just showing "Container" or "Image"

↓- How I did it
On fish completion, description can be added not only by
-d
option ofcomplete
command, but also by appending tab-separeted field for each candidate line.ref:
man complete
https://fishshell.com/docs/current/commands.html#completeSo I fixed the functions
__fish_print_docker_containers
and__fish_print_docker_images
to include information of candidates, and remove-d
option.- How to verify it
docker.fish
file under~/.config/fish/completions/
docker run
TAB ordocker stop
TAB etc- Description for the changelog
cli fish completion: enriched containers/images description
- A picture of a cute animal (not mandatory but encouraged)
Photo by @africansafari1, a zoo in Japan