From bc3876d0b36c4c57a918310fb7fdc1ab42eb4e79 Mon Sep 17 00:00:00 2001 From: Fredrik Ekre Date: Mon, 11 Apr 2022 18:08:13 +0200 Subject: [PATCH] [bash] Update colors for bash prompt. --- .bashrc.dotfiles | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/.bashrc.dotfiles b/.bashrc.dotfiles index b752406..21e3a86 100644 --- a/.bashrc.dotfiles +++ b/.bashrc.dotfiles @@ -23,8 +23,14 @@ fi # dotfiles alias alias dotfiles='git --git-dir="$HOME/.dotfiles.git/" --work-tree="$HOME/"' -# Common bash prompt -export PS1="[\[\e[32m\e[1m\]\u@\h\[\e[0m\]:\[\e[34m\e[1m\]\w\[\e[0m\]]\$ " +# Bash prompt +if [[ "${TERM}" =~ 256 ]]; then + # Colors from vim-airline bubblegum theme: 110 blue, 150 green + PS1="[\[\e[38;5;150m\e[1m\]\u@\h\[\e[0m\]:\[\e[38;5;110m\e[1m\]\w\e[0m\]]\$ " +else + PS1="[\[\e[32m\e[1m\]\u@\h\[\e[0m\]:\[\e[34m\e[1m\]\w\[\e[0m\]]\$ " +fi +export PS1 # Julia environment variables export JULIA_PKG_DEVDIR=$HOME/dev