diff options
Diffstat (limited to 'bashrc')
-rw-r--r-- | bashrc | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -193,14 +193,16 @@ if [ -n "$PS1" ]; then bind -r '' fi -export PROMPT_COMMAND=prompt_set_window_title - -if command -v zoxide > /dev/null; then - eval "$(zoxide init bash)" -fi +gotcmd() { + command -v "$1" > /dev/null +} -if command -v starship > /dev/null; then - eval "$(starship init bash)" +if gotcmd zoxide && gotcmd starship; then + export PROMPT_COMMAND=prompt_set_window_title + eval "$(zoxide init bash)" + eval "$(starship init bash)" +else + export PROMPT_COMMAND=prompt_command fi if [ -e "$HOME/.cargo/env" ] |