From 6dbf5eda31cbfb02acc9eccfdb72bca2cc9e1a57 Mon Sep 17 00:00:00 2001 From: Tmplt Date: Sun, 17 Jul 2016 14:53:34 +0200 Subject: [PATCH] [prompt] add ranger indicator to eriner theme closes #64 --- modules/prompt/themes/eriner.zsh-theme | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/modules/prompt/themes/eriner.zsh-theme b/modules/prompt/themes/eriner.zsh-theme index 302eaf6..134a81c 100644 --- a/modules/prompt/themes/eriner.zsh-theme +++ b/modules/prompt/themes/eriner.zsh-theme @@ -72,6 +72,16 @@ prompt_context() { fi } +# Ranger: , which can spawn ${SHELL} +# under its own process +prompt_ranger() { + if [[ $((RANGER_LEVEL)) -ne 0 ]]; then + local color=blue + prompt_segment ${color} ${PRIMARY_FG} + print -Pn " r" + fi +} + # Git: branch/detached head, dirty status prompt_git() { local color ref @@ -122,6 +132,7 @@ prompt_eriner_main() { CURRENT_BG='NONE' prompt_status prompt_context + prompt_ranger prompt_dir prompt_git prompt_end