提交 9cd67bd2 编写于 作者: F Felipe Contreras 提交者: Junio C Hamano

completion: fix warning for zsh

Otherwise the user might get something like:

  git-completion.sh:2466: command not found: compdef

If this script is loaded before compinit. The script would work either
way, but let's not be more annoying to the user.
Signed-off-by: NFelipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 bad27f41
...@@ -2404,6 +2404,8 @@ __gitk_main () ...@@ -2404,6 +2404,8 @@ __gitk_main ()
if [[ -n ${ZSH_VERSION-} ]]; then if [[ -n ${ZSH_VERSION-} ]]; then
echo "WARNING: this script is deprecated, please see git-completion.zsh" 1>&2 echo "WARNING: this script is deprecated, please see git-completion.zsh" 1>&2
autoload -U +X compinit && compinit
__gitcomp () __gitcomp ()
{ {
emulate -L zsh emulate -L zsh
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册