From fe0b1bea20e3f0055ea7c6adc6ac4981b50250cc Mon Sep 17 00:00:00 2001 From: Jocelyn Mallon Date: Tue, 15 Jul 2014 16:22:28 -0700 Subject: [PATCH] Add an option to show extended directory/path information. Add a user selectable option 'BULLETTRAIN_DIR_EXTENDED' to show extended directory/path information. Currently this is fixed at truncating the path shown at 3 folders deep, but could be modified to support user selectable nesting/truncation. --- bullet-train.zsh-theme | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bullet-train.zsh-theme b/bullet-train.zsh-theme index 8cd577c..416bc3e 100644 --- a/bullet-train.zsh-theme +++ b/bullet-train.zsh-theme @@ -186,8 +186,11 @@ prompt_dir() { if [[ $BULLETTRAIN_DIR_SHOW == false ]] then return fi - - prompt_segment $BULLETTRAIN_DIR_BG $BULLETTRAIN_DIR_FG '%1~' + if [[ $BULLETTRAIN_DIR_EXTENDED != true ]] then + prompt_segment $BULLETTRAIN_DIR_BG $BULLETTRAIN_DIR_FG '%1~' + else + prompt_segment $BULLETTRAIN_DIR_BG $BULLETTRAIN_DIR_FG '%4(c:...:)%3c' + fi } # RVM: only shows RVM info if on a gemset that is not the default one