diff options
author | Till Höppner | 2017-06-05 18:41:33 +0200 |
---|---|---|
committer | Till Höppner | 2017-06-05 18:41:33 +0200 |
commit | b0fe52d90ba0067bfb2f07455c5e0dc828ef8956 (patch) | |
tree | 74f66917059b011a303bc939dec1eacbaf197340 /conf.d | |
parent | ae50dcd19349bccf3727b76ae6d87c2c61df534f (diff) | |
download | zsh-b0fe52d90ba0067bfb2f07455c5e0dc828ef8956.tar.gz zsh-b0fe52d90ba0067bfb2f07455c5e0dc828ef8956.tar.xz zsh-b0fe52d90ba0067bfb2f07455c5e0dc828ef8956.zip |
Show connected docker machines in prompt
Diffstat (limited to 'conf.d')
-rw-r--r-- | conf.d/60-prompt.zsh | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/conf.d/60-prompt.zsh b/conf.d/60-prompt.zsh index c21aafc..1ae2531 100644 --- a/conf.d/60-prompt.zsh +++ b/conf.d/60-prompt.zsh @@ -64,6 +64,11 @@ left_prompt() { echo -n "@$(hostname | tr -d '\n') " fi + if test -n "$DOCKER_HOST"; then + zcol "$fg[cyan]" + echo -n "$(basename "$DOCKER_HOST") " + fi + zcol "$fg[green]" { pwd; echo -n " " } | tr -d '\n' | sed -e "s:^$HOME:~:" |