From fd237f2e6281a4c24c60d420bcf5fc73d5c4ceab Mon Sep 17 00:00:00 2001 From: Jacob Kiers Date: Wed, 25 Jun 2014 18:10:54 +0200 Subject: [PATCH] Fix terminal title for paths with spaces. Signed-off-by: Jacob Kiers --- includes/bash_prompt.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/bash_prompt.bash b/includes/bash_prompt.bash index f4a2e04..4746342 100644 --- a/includes/bash_prompt.bash +++ b/includes/bash_prompt.bash @@ -78,7 +78,7 @@ function prompt_command() { PS2="\[$CYAN\]$prompt_symbol\[$NOCOLOR\] " # Terminal title - local title="$(basename $PWD)" + local title=`basename "$PWD"` [ -n "$remote" ] && title="$title \xE2\x80\x94 $HOSTNAME" echo -ne "\033]0;$title"; echo -ne "\007" }