Fix missing slashes in short dir.
[profile.git] / .profile.d / ps1.bashrc
index 4f249c9..991095b 100644 (file)
@@ -240,7 +240,8 @@ function __ps1_short() {
     n=$((n+1))
   done
 
-  echo "$short$dirname"
+  [ "${short:0:1}" = "~" ] || short="/$short"
+  echo "$short/$dirname"
   return $1
 }