E117: Unknown function: plug#begin

32 views
Skip to first unread message

Rellot

unread,
Oct 26, 2022, 1:40:47 PM10/26/22
to vim_use

Rellot

unread,
Oct 26, 2022, 3:48:39 PM10/26/22
to vim_use

Hello, I was setting up vim plug when this error occured:

Error detected while processing .vimrc:
line 5:
E117: Unknown function: plug#begin
line 7:
E492: Not an editor command: Plug 'neoclide/coc.nvim'
line 9:
E117: Unknown function: plug#end

here's the .vimrc file

syntax on
filetype plugin indent on
set ts=2 sts=2 sw=2 et ai si
set rnu
call plug#begin()
Plug 'neoclide/coc.nvim'
call plug#end()

Rellot's Screwdriver

unread,
Oct 26, 2022, 3:48:50 PM10/26/22
to v...@vim.org
this error occured when conifiguring vim plugin
full error message:
```
Error detected while processing .vimrc:
line 5:
E117: Unknown function: plug#begin
line 7:
E492: Not an editor command: Plugin 'neoclide/coc.nvim'
line 9:
E117: Unknown function: plug#end
```

.vimrc (using vim 9.0)
```
syntax on
filetype plugin indent on
set ts=2 sts=2 sw=2 et ai si
set rnu
call plug#begin()

Plugin 'neoclide/coc.nvim'

call plug#end()
```

Tony Mechelynck

unread,
Oct 26, 2022, 4:12:55 PM10/26/22
to vim...@googlegroups.com
This means Vim is trying to load the function plug#begin() then the
function plug#end() from the script <something>/autoload/plug.vim
where <something> is any one of the directories mentioned in
'runtimepath', and either not finding that script, or not finding
these functions within it. It also doesn't find the user-command Plug
so the former (script not found) seems more likely.

Try adding the following at the top of your vimrc, it should give you
a warning message for not finding files to be sourced:

if &verbose < 2
set verbose=2
endif

Later you can manually :set vbs-=1 if you want to stop displaying all
those messages.

See :help autoload

Best regards,
Tony.

David Lowry-Duda

unread,
Oct 26, 2022, 6:17:41 PM10/26/22
to vim...@googlegroups.com
This sounds like an issue that is better suited for the vim-plug issue
tracker. I would guess that their first suggestion would be to check
that you downloaded the vim-plug plugin to the correct directory. I
suggest you include this in your description when you ask this at the
vim-plug repository.

Good luck - DLD

Owajigbanam Ogbuluijah

unread,
Oct 26, 2022, 7:05:10 PM10/26/22
to vim...@googlegroups.com
Hi Rellot,

From the syntax, you may be trying to use junegunn/vim-plug. Ensure vim-plug is properly installed. These errors mean Vim can't find the functions which would have normally been registered by the plugin.

3 things
  1. Ensure the plugin is properly installed
  2. Use Plug, not Plugin
  3. Ensure you provide the plugin directory in plug#begin(<directory>)

Cheers,
Igbanam.

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/16f36634-e4c5-4fe4-a242-ded3008b9e26n%40googlegroups.com.

Robert

unread,
Oct 28, 2022, 3:06:50 PM10/28/22
to vim_use
It's not finding where you put it. I do the following:

" installed at
~/.vim/autoload/plug.vim

" All my plugins are installed into this path
call plug#begin('~/.vim/plugged')

HTH

Bob
Reply all
Reply to author
Forward
0 new messages