diff options
author | Frank Terbeck <bewater@users.sourceforge.net> | 2011-12-30 13:32:51 +0000 |
---|---|---|
committer | Frank Terbeck <bewater@users.sourceforge.net> | 2011-12-30 13:32:51 +0000 |
commit | ee03cac7fea67062eff3340b018b8d38c35f6a95 (patch) | |
tree | 9ee2b9cbe0d9d14a8632298ebcc6764ad6e1052a /Functions/VCS_Info | |
parent | 30c98aa87ed0605f2e7cd254463624c062665cc8 (diff) | |
download | zsh-ee03cac7fea67062eff3340b018b8d38c35f6a95.tar.gz zsh-ee03cac7fea67062eff3340b018b8d38c35f6a95.tar.xz zsh-ee03cac7fea67062eff3340b018b8d38c35f6a95.zip |
30046: VCS_INFO_get_data_svn: Fix support for subversion version 1.7
Diffstat (limited to 'Functions/VCS_Info')
-rw-r--r-- | Functions/VCS_Info/Backends/VCS_INFO_get_data_svn | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/Functions/VCS_Info/Backends/VCS_INFO_get_data_svn b/Functions/VCS_Info/Backends/VCS_INFO_get_data_svn index b1cb7302b..41cc3e783 100644 --- a/Functions/VCS_Info/Backends/VCS_INFO_get_data_svn +++ b/Functions/VCS_Info/Backends/VCS_INFO_get_data_svn @@ -6,12 +6,28 @@ setopt localoptions noksharrays extendedglob NO_shwordsplit local svnbase svnbranch a b rrn +local -i rc local -A svninfo parentinfo local -xA hook_com svnbase="."; svninfo=() -${vcs_comm[cmd]} info --non-interactive | while IFS=: read a b; do svninfo[${a// /_}]="${b## #}"; done +# Unfortunately, `$pipestatus' is broken currently. Until that problem is +# resolved, here is a workaround that will get things done, without using it. +# Clumsily, but that's life. +local -a dat +dat=( ${(f)"$(${vcs_comm[cmd]} info --non-interactive 2>&1)"} ) +rc=$? +(( rc != 0 )) && return 1 +# The following line is the real code, the following is the workaround. +#${vcs_comm[cmd]} info --non-interactive \ +print -l "${dat[@]}" \ +|& while IFS=: read a b; do + svninfo[${a// /_}]="${b## #}" +done +#rc=${pipestatus[1]} +#(( rc != 0 )) && return 1 + while [[ -d "${svnbase}/../.svn" ]]; do parentinfo=() ${vcs_comm[cmd]} info --non-interactive "${svnbase}/.." | while IFS=: read a b; do parentinfo[${a// /_}]="${b## #}"; done |