From: Brandon Casey <>

This reverts commit 69a8141a5d81925b7e08cb228535e9ea4a7a02e3.

Old Bash (3.0) which is distributed with RHEL 4.X and other ancient
platforms that are still in wide use, does not have a printf that
supports -v.  Let's revert this patch and go back to using printf
in the traditional way.

Signed-off-by: Brandon Casey <>
 contrib/completion/ | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/contrib/completion/ b/contrib/completion/
index a81ef5a..7698ec4 100644
--- a/contrib/completion/
+++ b/contrib/completion/
@@ -433,11 +433,7 @@ __git_ps1 ()
        local gitstring="$c${b##refs/heads/}${f:+$z$f}$r$p"
        if [ $pcmode = yes ]; then
-               if [[ -n ${ZSH_VERSION-} ]]; then
-                       gitstring=$(printf -- "$printf_format" "$gitstring")
-               else
-                       printf -v gitstring -- "$printf_format" "$gitstring"
-               fi
+               gitstring=$(printf -- "$printf_format" "$gitstring")
                printf -- "$printf_format" "$gitstring"

This email message is for the sole use of the intended recipient(s) and may 
confidential information.  Any unauthorized review, use, disclosure or 
is prohibited.  If you are not the intended recipient, please contact the 
sender by
reply email and destroy all copies of the original message.
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to
More majordomo info at

Reply via email to