Merge pull request #23891 from sdurrheimer/zsh-completion-run-storage-opt

Add zsh completion for 'docker run --storage-opt size='
This commit is contained in:
Vincent Demeester 2016-06-23 10:11:02 +02:00 committed by GitHub
commit 6211570de1

View file

@ -1251,6 +1251,7 @@ __docker_subcommand() {
"($help)--rm[Remove intermediate containers when it exits]" \ "($help)--rm[Remove intermediate containers when it exits]" \
"($help)--sig-proxy[Proxy all received signals to the process (non-TTY mode only)]" \ "($help)--sig-proxy[Proxy all received signals to the process (non-TTY mode only)]" \
"($help)--stop-signal=[Signal to kill a container]:signal:_signals" \ "($help)--stop-signal=[Signal to kill a container]:signal:_signals" \
"($help)--storage-opt=[Set storage driver options per container]:storage options:->storage-opt" \
"($help -): :__docker_images" \ "($help -): :__docker_images" \
"($help -):command: _command_names -e" \ "($help -):command: _command_names -e" \
"($help -)*::arguments: _normal" && ret=0 "($help -)*::arguments: _normal" && ret=0
@ -1263,6 +1264,14 @@ __docker_subcommand() {
__docker_runningcontainers -qS ":" && ret=0 __docker_runningcontainers -qS ":" && ret=0
fi fi
;; ;;
(storage-opt)
if compset -P "*="; then
_message "value" && ret=0
else
opts=('size')
_describe -t filter-opts "storage options" opts -qS "=" && ret=0
fi
;;
esac esac
;; ;;