Python 的 Vim 自动完成 [英] Vim autocomplete for Python

查看:30
本文介绍了Python 的 Vim 自动完成的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在 Vim 中加入自动完成功能.我使用了 Vim 的 omnicompletion 以及 Pydiction.但在这两种情况下都会弹出此消息:

I am trying to incorporate an autocomplete feature in Vim. I have used the omnicompletion of Vim as well as Pydiction. But in both the cases this message pops up:

Omni 完成 (^O^N^P) 模式未找到

我已经尝试过Vim 的 Python Omnicompletion 只是不起作用.但这并没有帮助.有解决方法吗?

I have tried Vim's Omnicompletion with Python just doesn't work. But this is not helping. Is there a workaround?

推荐答案

试试绝地https://github.com/davidhalter/jedi-vim 上有一个 Vim 插件.

Try Jedi! There's a Vim plugin at https://github.com/davidhalter/jedi-vim.

它比 Vim 中的 Python 的其他任何东西都好得多.它甚至支持重命名、跳转等.最好的部分可能是它真的试图理解您的代码(装饰器、生成器等.只需查看功能列表).

It works just much better than anything else for Python in Vim. It even has support for renaming, goto, etc. The best part is probably that it really tries to understand your code (decorators, generators, etc. Just look at the feature list).

这篇关于Python 的 Vim 自动完成的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆