update-bash: fully resolve Git's path in hash.

Otherwise Bash can cache a relative PATH and then get upset when it
changes directory and cannot find it any more.

Closes Homebrew/homebrew#48493.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
This commit is contained in:
Mike McQuaid 2016-01-26 17:06:25 +00:00
parent 99fd172ea8
commit e07b5a98e0

View File

@ -271,6 +271,7 @@ EOS
odie "Git must be installed and in your PATH!"
fi
fi
hash -p "$(cd "$(dirname "$(which_git)")" && pwd -P)/git" git
if [[ -z "$HOMEBREW_VERBOSE" ]]
then