1
0
mirror of https://github.com/docker/cli.git synced 2026-01-25 03:42:05 +03:00
Files
cli/components
Vincent Bernat fe2d726b98 zsh: fix completion when docker output only has the header line
Unfortunately, `(f)` aka `(ps:\n:)` flag will not create an array when
there is only one line. The subsequent use of indexes will then affect
the string. This leads to `docker rmi <tab>` to complete on the header
line instead of nothing.

Therefore, for each use of `(f)`, we ensure that we have an extra new
line to be sure we get an array.

Credit to @povesteam for the original report and fix in #27373.

Signed-off-by: Vincent Bernat <vincent@bernat.im>
Upstream-commit: 44b83c56b6e52e08e5c1e580b042421069707286
Component: engine
2016-10-17 17:23:09 +02:00
..