Code

completion: don't leak variable from the prompt into environment
[git.git] / contrib / completion / git-completion.bash
index fc3d0b1a0678ddf99c592959d2fe58c59543ec40..32df141f919fc48dd0310eabd4b510814f09f384 100755 (executable)
@@ -110,7 +110,7 @@ __git_ps1_show_upstream ()
        local upstream=git legacy="" verbose=""
 
        # get some config options from git-config
-       output="$(git config -z --get-regexp '^(svn-remote\..*\.url|bash\.showupstream)$' 2>/dev/null | tr '\0\n' '\n ')"
+       local output="$(git config -z --get-regexp '^(svn-remote\..*\.url|bash\.showupstream)$' 2>/dev/null | tr '\0\n' '\n ')"
        while read key value; do
                case "$key" in
                bash.showupstream)