mirror of
git://git.code.sf.net/p/zsh/code
synced 2026-01-04 09:01:06 +01:00
Frank Terbeck: 27353: more VCS_Info sanity checks
This commit is contained in:
parent
39e4cfd4db
commit
d6c4e4c692
3 changed files with 9 additions and 1 deletions
|
|
@ -8,6 +8,7 @@ local basedir="." realbasedir
|
|||
|
||||
realbasedir="$(VCS_INFO_realpath ${basedir})"
|
||||
while [[ ${realbasedir} != '/' ]]; do
|
||||
[[ -r ${realbasedir} ]] || return 1
|
||||
if [[ -n ${vcs_comm[detect_need_file]} ]] ; then
|
||||
[[ -d ${basedir}/${dirname} ]] && \
|
||||
[[ -e ${basedir}/${dirname}/${vcs_comm[detect_need_file]} ]] && \
|
||||
|
|
|
|||
|
|
@ -41,6 +41,8 @@ vcs_info () {
|
|||
emulate -L zsh
|
||||
setopt extendedglob
|
||||
|
||||
[[ -r . ]] || return 0
|
||||
|
||||
local pat
|
||||
local -i found
|
||||
local -a enabled disabled dps
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue