Home > Backend Development > PHP Tutorial > Why does the Vim that comes with CentOS have auto-completion, but the one that comes with Mac doesn't?

Why does the Vim that comes with CentOS have auto-completion, but the one that comes with Mac doesn't?

WBOY
Release: 2016-09-05 08:59:55
Original
1163 people have browsed it

As mentioned, I was looking at some CentOS help and found that its own Vim has an auto-completion function by default, which is what comes out of Ctrl+x, then Ctrl+o.
However, the Vim that comes with Mac does not come with it. I modified some other configurations of Vim under Mac, such as turning on code highlighting, but I don’t know how to do this automatic completion. I also went to CentOS’s /etc/vimrc and /usr I went to /share/vim and looked at it, but I didn’t understand the meaning of the things in the folder under vim. In theory, if the code completion is a plug-in, then I can see it loaded in /etc/vimrc, but it doesn’t.
If it’s not a plug-in, then why doesn’t Vim come with Mac?

I hope the seniors will give you some advice, thank you.

I know, there is a prompt on Mac that ‘omnifunc’ is not set. After checking, this default plug-in seems to be called Omni completion, which is implemented using the things in the autoload directory under the Vim7x directory, but I don’t know how to set it up

Update:

Okay, I solved it myself.

Reply content:

As mentioned, I was looking at some CentOS help and found that its own Vim has an auto-completion function by default, which is what comes out of Ctrl+x, then Ctrl+o.
However, the Vim that comes with Mac does not come with it. I modified some other configurations of Vim under Mac, such as turning on code highlighting, but I don’t know how to do this automatic completion. I also went to CentOS’s /etc/vimrc and /usr I went to /share/vim and looked at it, but I didn’t understand the meaning of the things in the folder under vim. In theory, if the code completion is a plug-in, then I can see it loaded in /etc/vimrc, but it doesn’t.
If it’s not a plug-in, then why doesn’t Vim come with Mac?

I hope the seniors will give you some advice, thank you.

I know, there is a prompt on Mac that ‘omnifunc’ is not set. After checking, this default plug-in seems to be called Omni completion, which is implemented using the things in the autoload directory under the Vim7x directory, but I don’t know how to set it up

Update:

Okay, I solved it myself.

vim --version

You are talking about super tag, that completion is not very smart, you can try the ycm plug-in which is very useful

Amway a project to make Vim more efficient

:scriptnames See the difference in scripts used by the two platforms.

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template