summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2019-12-23 18:01:25 +0100
committerGitHub <noreply@github.com>2019-12-23 18:01:25 +0100
commitd43bff7cc6484927487ded4246e7625c8b42b5e8 (patch)
tree62a98b80b2fd4349db669472e64ddec695ca7851
parent9bf7315882dd6565e43754d1d7ab7cfa44b00820 (diff)
parent3467f24fce1f9919b9efde5a9e755f2e167bc972 (diff)
downloadpodman-d43bff7cc6484927487ded4246e7625c8b42b5e8.tar.gz
podman-d43bff7cc6484927487ded4246e7625c8b42b5e8.tar.bz2
podman-d43bff7cc6484927487ded4246e7625c8b42b5e8.zip
Merge pull request #4740 from edsantiago/zsh_completion_flagfix
zsh completion: ignore multi-line output in Flags
-rw-r--r--completions/zsh/_podman1
1 files changed, 1 insertions, 0 deletions
diff --git a/completions/zsh/_podman b/completions/zsh/_podman
index 228498066..06aa92748 100644
--- a/completions/zsh/_podman
+++ b/completions/zsh/_podman
@@ -47,6 +47,7 @@ _read_podman_flags() {
# The result will be, e.g. '-f,--foo=string Description of Option'
_call_program podman podman "$@" --help |\
sed -n -e '0,/^Flags:/d' -e '/^$/q;p' |\
+ grep '^ \+-' |\
sed -e 's/^ *//' -e 's/^\(-.,\) --/\1--/' |\
sed -e 's/^\(-[^ ]\+\) \([^ ]\+\) /\1=\2 /' |\
while read flags desc;do