summaryrefslogtreecommitdiff
path: root/modules/programs
diff options
context:
space:
mode:
authorDaiderd Jordan <daiderd@gmail.com>2017-07-18 22:34:09 +0200
committerDaiderd Jordan <daiderd@gmail.com>2017-07-18 22:34:09 +0200
commit61cd181a0f334584c467e3a9d1f3aac023e7c601 (patch)
treee20ccd8c8ee502e5862faa8e52e34bd6c0a34b36 /modules/programs
parent0a1461ce7d8553c2c0d7140ca646e36d6180ee93 (diff)
zsh: use container names for fzf docker completion
Diffstat (limited to 'modules/programs')
-rw-r--r--modules/programs/zsh/fzf-completion.zsh4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/programs/zsh/fzf-completion.zsh b/modules/programs/zsh/fzf-completion.zsh
index a4a566c..486eeff 100644
--- a/modules/programs/zsh/fzf-completion.zsh
+++ b/modules/programs/zsh/fzf-completion.zsh
@@ -125,8 +125,8 @@ _fzf_complete_docker_post() {
local cmd
cmd=${tokens[2]}
case $cmd in
- image|push|rmi|run) awk '{print $1 ":" $2}' ;;
- *) awk '{print $1}' ;;
+ image|push|rmi|run) awk '{ print ($2 == "<none>") ? $3 : $1 ":" $2}' ;;
+ *) awk '{print $NF}' ;;
esac
}