diff --git a/git-extra/PKGBUILD b/git-extra/PKGBUILD index 99a512ee08..ef1c25aa37 100644 --- a/git-extra/PKGBUILD +++ b/git-extra/PKGBUILD @@ -5,7 +5,7 @@ pkgbase="mingw-w64-${_realname}" pkgname=($_realname "${MINGW_PACKAGE_PREFIX}-${_realname}") _ver_base=1.1 -pkgver=1.1.667.036188a82 +pkgver=1.1.674.6bde10035 pkgrel=1 pkgdesc="Git for Windows extra files" arch=('any') @@ -74,7 +74,7 @@ sha256sums=('8ed76d1cb069ac8568f21c431f5e23caebea502d932ab4cdff71396f4f0d5b72' 'd212e1bbe75a9f81443126701324c9c44c3ed5750dd9822eba754a1799ed13b3' '402c51eba82453a76f5110f4754bb1005df507a6e4532574c2b9627ff4e1dc81' '8433a9e72b3bc9c3bc7903b54b868399bdb17a6c8de4af4dd5450dd42859c898' - '0a4d04eb5ce035f9b94ebad51f0fc366ffda1f384fa6e586e8eef140440fb012' + '48e7327ad51e6b31fde3287aec8df1ee6e312dee2211bee331a6297f61c438f9' '8056f48ae61f2cba668c07b31c56229914912444ca6656205aaffce59b8e6b11' '32c9a549ecb1c9e06622221dae98a000ac2ce9c2be97d5d0c4f80610af3dc55c' '02d38e480a1ec4227e94a5aa073945901680aa3387e3386f8b77f10426ebbc75' diff --git a/git-extra/git-prompt.sh b/git-extra/git-prompt.sh index c8a5fa8dee..2d5118d248 100755 --- a/git-extra/git-prompt.sh +++ b/git-extra/git-prompt.sh @@ -1,3 +1,7 @@ +#!/bin/sh +newline=' +' + if test -f /etc/profile.d/git-sdk.sh then TITLEPREFIX=SDK-${MSYSTEM#MINGW} @@ -25,10 +29,21 @@ else COMPLETION_PATH="$COMPLETION_PATH/share/git/completion" if test -f "$COMPLETION_PATH/git-prompt.sh" then - . "$COMPLETION_PATH/git-completion.bash" - . "$COMPLETION_PATH/git-prompt.sh" - PS1="$PS1"'\[\033[36m\]' # change color to cyan - PS1="$PS1"'`__git_ps1`' # bash function + . "$COMPLETION_PATH/git-prompt.sh" + if test -n "$ZSH_VERSION" # Avoids zsh git-completion.bash Error. + then + # Assembles git prompt that closely resembles the default bash prompt. + precmd() + { + pre="${newline}%F{green}%n@%m%f %F{magenta}${MSYSTEM:-"ZSH"}%f %F{yellow}%~%f %F{cyan}" + post="%f${newline}$ " + __git_ps1 "${pre}" "${post}" "(%s)" + } + else + . "$COMPLETION_PATH/git-completion.bash" + PS1="$PS1"'\[\033[36m\]' # change color to cyan + PS1="$PS1"'`__git_ps1`' # bash function + fi fi fi PS1="$PS1"'\[\033[0m\]' # change color