mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Filter completions of docker inspect
by --type
Completion now filters the images and containers by given `--type`. Signed-off-by: Harald Albers <github@albersweb.de>
This commit is contained in:
parent
f9a2b3650b
commit
69cde5a302
1 changed files with 11 additions and 2 deletions
|
@ -738,8 +738,17 @@ _docker_inspect() {
|
|||
COMPREPLY=( $( compgen -W "--format -f --type --help" -- "$cur" ) )
|
||||
;;
|
||||
*)
|
||||
case $(__docker_value_of_option --type) in
|
||||
'')
|
||||
__docker_containers_and_images
|
||||
;;
|
||||
container)
|
||||
__docker_containers_all
|
||||
;;
|
||||
image)
|
||||
__docker_image_repos_and_tags_and_ids
|
||||
;;
|
||||
esac
|
||||
esac
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue