summaryrefslogtreecommitdiff
path: root/git-prompt.sh
diff options
context:
space:
mode:
Diffstat (limited to 'git-prompt.sh')
-rw-r--r--git-prompt.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/git-prompt.sh b/git-prompt.sh
index d21786a..54ef999 100644
--- a/git-prompt.sh
+++ b/git-prompt.sh
@@ -1,3 +1,8 @@
+
+# don't set prompt if this is not interactive shell
+# it is better if this test is done before git-prompt.sh is sources for perfomanse reasons.
+[[ $- != *i* ]] && return
+
##################################################################### CONFIG
default_user=lvv # default user is not displayed
default_host="ahp" # default host is not displayed