From 1b78dfb6c88bbb0c71cc0f2d1f91ada2dc9ddd89 Mon Sep 17 00:00:00 2001 From: Martin Gondermann Date: Tue, 1 Jul 2014 19:47:54 +0200 Subject: [PATCH] Implemented a per repository possibility to turn of the fetching of the remote status (fixes #59) --- gitprompt.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/gitprompt.sh b/gitprompt.sh index 03d288a..cbd3f3d 100755 --- a/gitprompt.sh +++ b/gitprompt.sh @@ -183,7 +183,15 @@ function setGitPrompt() { return fi - checkUpstream + local FETCH_REMOTE_STATUS=true + if [[ -e "${repo}/.bash-git-rc" ]]; then + source "${repo}/.bash-git-rc" + fi + + if [ "${FETCH_REMOTE_STATUS}" == "true" ]; then + checkUpstream + fi + updatePrompt }