preserve-cwd
This commit is contained in:
parent
d03b5e7e25
commit
facaccc381
|
@ -79,14 +79,14 @@ fi
|
||||||
git_prompt_info_no_space() {
|
git_prompt_info_no_space() {
|
||||||
current="$PWD"
|
current="$PWD"
|
||||||
while [ "$PWD" != "/" ] && [ ! -d "$PWD/.git" ]; do
|
while [ "$PWD" != "/" ] && [ ! -d "$PWD/.git" ]; do
|
||||||
cd ..
|
builtin cd ..
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ -f "$PWD/.gitskipprompt" ]; then
|
if [ -f "$PWD/.gitskipprompt" ]; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd "$current"
|
builtin cd "$current"
|
||||||
local info=$(git_prompt_info)
|
local info=$(git_prompt_info)
|
||||||
if [ ! -z $info ]; then
|
if [ ! -z $info ]; then
|
||||||
echo " $info"
|
echo " $info"
|
||||||
|
|
Loading…
Reference in New Issue