ubuntu 14.04 apt/aptitude autocompletion与oh-my-zsh无法正常工作

ate*_*eam 5 ubuntu zsh autocomplete zsh-completion oh-my-zsh

我最近开始在Ubuntu 14.04服务器中使用zsh和oh-my-zsh.问题是debian插件的自动完成不起作用,即

ai something<TAB>
Run Code Online (Sandbox Code Playgroud)

不自动完成.当然

aptitude install somethi<TAB>
apt-get install somethi<TAB>
Run Code Online (Sandbox Code Playgroud)

做得对.oh-my-zsh的git插件也没有任何问题.

所以我开始怀疑是否有人能解决这个问题.

如果有人需要更多信息,这里有一些相关的包:

?  aps zsh completion
p   bash-completion                                           - programmable completion for the bash shell
v   bash-completion:i386                                      -
p   fatrat-czshare                                            - fatrat plugin allowing download and upload to czshare
p   fatrat-czshare:i386                                       - fatrat plugin allowing download and upload to czshare
p   fizsh                                                     - Friendly Interactive ZSHell
v   git-completion                                            -
v   git-completion:i386                                       -
v   ncmpcpp-completion                                        -
v   ncmpcpp-completion:i386                                   -
i   zsh                                                       - shell with lots of features
p   zsh:i386                                                  - shell with lots of features
p   zsh-beta                                                  - transitional package to zsh
p   zsh-beta-doc                                              - transitional package to zsh-doc
i A zsh-common                                                - architecture independent files for Zsh
p   zsh-dbg                                                   - shell with lots of features (debugging symbols)
p   zsh-dbg:i386                                              - shell with lots of features (debugging symbols)
p   zsh-dev                                                   - shell with lots of features (development files)
p   zsh-dev:i386                                              - shell with lots of features (development files)
i   zsh-doc                                                   - zsh documentation - info/HTML format
p   zsh-lovers                                                - tips, tricks and examples for the zsh
p   zsh-static                                                - shell with lots of features (static link)
p   zsh-static:i386                                           - shell with lots of features (static link)
p   zshdb                                                     - debugger for Z-Shell scripts
Run Code Online (Sandbox Code Playgroud)

aze*_*eey 5

添加

setopt completealiases
Run Code Online (Sandbox Code Playgroud)

加载oh-my-zsh之后似乎解决了这个问题.