vim - NeoVim 插件未安装。(使用 vim 插件)
问题描述
请帮助我在为我的 NeoVim 设置我的 init.vim 时遇到这个奇怪的问题。所以以下是我的 init.vim 文件。这没有显示任何错误。但是当我想安装插件时。在我运行后,:PlugInstall
只有 vim-code-dark 正在安装。没有安装其他插件,即 vim-polyglot 和 NERDTree。请告诉我我哪里出错了。我被困在这里两天了,但无法设置我的 Vim 编辑器。
" Auto-Install vim-plug
if empty(glob('~/.config/nvim/autoload/plug.vim'))
silent !curl -fLo ~/.config/nvim/autoload/plug.vim --create-dirs
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
"autocmd VimEnter * PlugInstall
"autocmd VimEnter * PlugInstall | source $MYVIMRC
endif
"__________________________________________________________________________________________
" Vim-Editor Plugins
call plug#begin('~/.config/nvim/autoload/plugged')
Plug 'sheerun/vim-polyglot'
Plug 'scrooloose/NERDTree'
Plug 'jiangmiao/auto-pairs'
call plug#end()
"__________________________________________________________________________________________
" General Editor Settings
" set leader key
let g:mapleader = "\<ALT>"
" vim basics
set encoding=utf-8
syntax enable
set relativenumber
set noswapfile
set scrolloff=4
set backspace=indent,eol,start
" vim basics
set encoding=utf-8
syntax enable
set relativenumber
set noswapfile
set scrolloff=4
set backspace=indent,eol,start
" indentation
set tabstop=4
set softtabstop=4
set shiftwidth=4
set expandtab
set autoindent
set fileformat=unix
set incsearch
set ignorecase
set smartcase
set nohlsearch
set nobackup
set nowrap
filetype plugin indent on
" autocompletion
set updatetime=300
"__________________________________________________________________________________________
" Vim Themes
call plug#begin('~/.config/nvim/autoload/plugged')
Plug 'tomasiser/vim-code-dark'
call plug#end()
colorscheme codedark
let g:airline_theme = 'codedark'
解决方案
你有两个plug
块,这会混淆 vim-plug。移动vim-code-dark
到较早的plug
-block 并删除第二个。
推荐阅读
- python - python中的语法错误,同时获取数据到power bi
- asp.net - 代理 aspx 页面
- python - 在美丽的汤中找到下一个 div 标签
- firebase - 为什么有时 imageUrl 会保存在云 Firestore 数据库中,而有时却没有保存
- c - 我试图找出一种将月份名称转换为整数的方法
- python - 在 Python 中,如何找出哪个模块导入了特定模块
- php - 处理对象数组
- java - java.lang.RuntimeException:无法获取提供程序 com.google.android.gms.ads.MobileAdsInitProvider:java.lang.IllegalStateException:
- python-3.x - 为什么会出现错误:预期的字符串或类似字节的对象
- ssl - “SSL:错误:0B080074:x509 证书例程:X509_check_private_key:key values mismatch”即使我的密钥和 CRT 匹配