mirror of
git://git.code.sf.net/p/zsh/code
synced 2024-09-28 15:01:21 +02:00
43585: vcs_info svn: Recognize working copies in need of an upgrade.
This commit is contained in:
parent
0290757ed4
commit
abc94e8f6a
@ -1,3 +1,8 @@
|
||||
2018-10-07 Daniel Shahaf <d.s@daniel.shahaf.name>
|
||||
|
||||
* 43585: Functions/VCS_Info/Backends/VCS_INFO_get_data_svn:
|
||||
vcs_info svn: Recognize working copies in need of an upgrade.
|
||||
|
||||
2018-10-03 Peter Stephenson <p.stephenson@samsung.com>
|
||||
|
||||
* unposted: Etc/FAQ.yo: minor typos.
|
||||
|
@ -9,6 +9,7 @@ local svnbase svnbranch a b rrn
|
||||
local -i rc
|
||||
local -A svninfo parentinfo cwdinfo
|
||||
local -A hook_com
|
||||
integer -r SVN_ERR_WC_UPGRADE_REQUIRED=155036 # from /usr/local/include/subversion-1/svn_error_codes.h
|
||||
|
||||
svnbase=".";
|
||||
svninfo=()
|
||||
@ -18,7 +19,15 @@ svninfo=()
|
||||
local -a dat
|
||||
dat=( ${(f)"$(${vcs_comm[cmd]} info --non-interactive 2>&1)"} )
|
||||
rc=$?
|
||||
(( rc != 0 )) && return 1
|
||||
if (( rc != 0 )) ; then
|
||||
if (( rc == 1 )) && [[ -n ${(M)dat:#"svn: E${SVN_ERR_WC_UPGRADE_REQUIRED}: "*} ]]; then
|
||||
hook_com=()
|
||||
VCS_INFO_formats '' '?' '?' '' '' '?' 'upgrade required'
|
||||
return $?
|
||||
else
|
||||
return 1
|
||||
fi
|
||||
fi
|
||||
# The following line is the real code, the following is the workaround.
|
||||
#${vcs_comm[cmd]} info --non-interactive \
|
||||
print -l "${dat[@]}" \
|
||||
|
Loading…
Reference in New Issue
Block a user