From f588b6d660b6481c7b47e0a12d29372d0aa8ae8d Mon Sep 17 00:00:00 2001 From: Yigit Sever Date: Tue, 20 Aug 2024 09:46:07 +0200 Subject: fish: add node version to right prompt --- .config/fish/functions/fish_right_prompt.fish | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.config/fish/functions/fish_right_prompt.fish b/.config/fish/functions/fish_right_prompt.fish index 5963ed9..1e28dfc 100644 --- a/.config/fish/functions/fish_right_prompt.fish +++ b/.config/fish/functions/fish_right_prompt.fish @@ -76,6 +76,11 @@ function fish_right_prompt --description 'Write out the right prompt' set virtualenv "$green 🐍 " (basename "$VIRTUAL_ENV") end + set -l node_version + if set -q nvm_current_version + set node_version "$red  " "$nvm_current_version" + end + set hour $blue(date '+%R') - echo -n -s $virtualenv ' ' $repo_info ' ' $hour + echo -n -s $node_version ' ' $virtualenv ' ' $repo_info ' ' $hour end -- cgit v1.2.3-70-g09d2