--- /usr/local/share/zsh/4.2.6/functions/Completion/X/_acroread.dist Sun Jan 15 13:52:52 2006 +++ /usr/local/share/zsh/4.2.6/functions/Completion/X/_acroread Sun Jan 15 14:19:03 2006 @@ -4,15 +4,16 @@
# Try extracting the version number directly from the executable. # (This will fail if the executable is a wrapper script for acroread.) -local ver=${${${(f)"$(<$commands[$words[1]])"}:#^ver=*}##ver=} -[[ -n $ver ]] && _acroread_version=$ver +#local ver=${${${(f)"$(<$commands[$words[1]])"}:#^ver=*}##ver=} +#[[ -n $ver ]] && _acroread_version=$ver
-if (( ! $+_acroread_version )); then - local acropath=${${(s. .)${${(f)"$($words[1] -help 2>&1)"}[1]}}[2]} - _acroread_version=${${${(f)"$(<$acropath)"}:#^ver=*}##ver=} -fi +#if (( ! $+_acroread_version )); then +# local acropath=${${(s. .)${${(f)"$($words[1] -help 2>&1)"}[1]}}[2]} +# _acroread_version=${${${(f)"$(<$acropath)"}:#^ver=*}##ver=} +#fi
-if [[ $_acroread_version == 7.* ]]; then +#if [[ $_acroread_version == 7.* ]]; then +if true; then _arguments -C \ '--display=:X display:_x_display' \ '--screen=:X screen (overrides the screen part of DISPLAY)' \
俺はこれを挿入。以前のバージョンにこのオプションがあったかどうか 知らないが、どうせそんなの使うことはないだろうからいいやと。 if (( ! $+_acroread_version )); then _acroread_version=$($words[1] -version 2>/dev/null) fi