ddc.vimでvim-lspエラーが出る
解決したいこと
vi
vim
起動時にエラーが出る。
発生している問題・エラー
[ddc] Not found source: vim-lsp
該当するソースコード
vimrc
.vimrc
let s:vimdir = has('nvim') ? '~/.config/nvim/' : '~/.vim/'
let s:plugdir = s:vimdir . 'plugged'
let s:plugfile = s:vimdir . 'autoload/plug.vim'
let s:plugurl = 'https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
if empty(glob(s:plugfile))
silent !echo '[Downloading vim-plug] ...'
silent execute '!mkdir -p ' . s:vimdir . 'autoload'
if executable('curl')
silent execute '!curl -sLo ' . s:plugfile ' ' . s:plugurl
elseif executable('wget')
silent execute '!wget -q -O ' . s:plugfile ' ' . s:plugurl
else
silent !echo 'vim-plug failed: you need either wget or curl' | cquit
endif
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif
call plug#begin(s:plugdir)
" color iceberg
Plug 'cocopon/iceberg.vim'
"" kakko
Plug 'cohama/lexima.vim'
"" gcc -> comment
Plug 'tpope/vim-commentary'
"" option bar
Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-theme'
"" auto bracket
Plug 'Raimondi/delimitMate'
"" delete white space
Plug 'bronson/vim-trailing-whitespace'
"" deoplete (auto complete)
if has('nvim')
" Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
else
" Plug 'Shougo/deoplete.nvim'
Plug 'roxma/nvim-yarp'
" Plug 'roxma/vim-hug-neovim-rpc'
endif
"" Super Tab
Plug 'ervandew/supertab'
"" Java
"" Plug 'takkii/Tea_Coffee'
"" DDC
Plug 'Shougo/ddc.vim'
Plug 'vim-denops/denops.vim'
Plug 'vim-denops/denops-helloworld.vim'
Plug 'Shougo/ddc-around'
Plug 'Shougo/ddc-matcher_head'
Plug 'Shougo/ddc-sorter_rank'
Plug 'prabirshrestha/vim-lsp'
Plug 'mattn/vim-lsp-settings'
call plug#end()
" call ddc#custom#patch_global('completionMenu', 'pum.vim')
call ddc#custom#patch_global('ui', 'pum.vim')
call ddc#custom#patch_global('sources', [
\ 'around',
\ 'vim-lsp',
\ 'file'
\ ])
call ddc#custom#patch_global('sourceOptions', {
\ '_': {
\ 'matchers': ['matcher_head'],
\ 'sorters': ['sorter_rank'],
\ 'converters': ['converter_remove_overlap'],
\ },
\ 'around': {'mark': 'Around'},
\ 'vim-lsp': {
\ 'mark': 'LSP',
\ 'matchers': ['matcher_head'],
\ 'forceCompletionPattern': '\.|:|->|"\w+/*'
\ },
\ 'file': {
\ 'mark': 'file',
\ 'isVolatile': v:true,
\ 'forceCompletionPattern': '\S/\S*'
\ }})
call ddc#enable()
inoremap <Tab> <Cmd>call pum#map#insert_relative(+1)<CR>
inoremap <S-Tab> <Cmd>call pum#map#insert_relative(-1)<CR>
let g:denops#deno = '/Users/UserName/.deno/bin/deno'
"" deoplete
" let g:deoplete#enable_at_startup = 1
let g:SuperTabDefaultCompletionType = '<C-n>'
"" vim-airline
let g:airline_theme = 'iceberg' "iceberg's color is going bad.(200603)
" let g:airline_theme = 'bubblegum'
let g:airline#extensions#syntastic#enabled = 1
let g:airline#extensions#branch#enabled = 1
let g:airline#extensions#tabline#enabled = 1
let g:airline#extensions#tagbar#enabled = 1
let g:airline_skip_empty_sections = 1
if !exists('g:airline_symbols')
let g:airline_symbols = {}
endif
if !exists('g:airline_powerline_fonts')
let g:airline#extensions#tabline#left_sep = ' '
let g:airline#extensions#tabline#left_alt_sep = '|'
let g:airline_left_sep = ''
let g:airline_left_alt_sep = '»'
let g:airline_right_se = ''
let g:airline_right_alt_sep = '«'
let g:airline#extensions#branch#prefix = '⤴' "➔, ➥, ⎇
let g:airline#extensions#readonly#symbol = '⊘'
let g:airline#extensions#linecolumn#prefix = '¶'
let g:airline#extensions#paste#symbol = 'ρ'
let g:airline_symbols.linenr = '␊'
let g:airline_symbols.branch = '⎇'
let g:airline_symbols.paste = 'ρ'
let g:airline_symbols.paste = 'Þ'
let g:airline_symbols.paste = '∥'
let g:airline_symbols.whitespace = 'Ξ'
"
else
let g:airline#extensions#tabline#left_sep = ''
let g:airline#extensions#tabline#left_alt_sep = ''
let g:airline_left_sep = ''
let g:airline_left_alt_sep = ''
let g:airline_right_sep = ''
let g:airline_right_alt_sep = ''
let g:airline_symbols.branch = ''
let g:airline_symbols.readonly = ''
let g:airline_symbols.linenr = ''
endif
" let g:airline_left_sep = '»'
" let g:airline_left_sep = '▶'
" let g:airline_right_sep = '«'
" let g:airline_right_sep = '◀'
" let g:airline_symbols.crypt = '🔒'
" let g:airline_symbols.linenr = '␊'
" let g:airline_symbols.linenr = ''
" let g:airline_symbols.linenr = '¶'
" let g:airline_symbols.maxlinenr = '☰'
" let g:airline_symbols.maxlinenr = ''
" let g:airline_symbols.branch = '⎇'
" let g:airline_symbols.paste = 'ρ'
" let g:airline_symbols.paste = 'Þ'
" let g:airline_symbols.paste = '∥'
" let g:airline_symbols.spell = 'Ꞩ'
" let g:airline_symbols.notexists = '∄'
" let g:airline_symbols.whitespace = 'Ξ'
"" colorscheme
colorscheme iceberg
" Base settings (without plug-in)
set encoding=utf-8
filetype off
filetype indent plugin off
" base
set fileencoding=utf-8
set fileencodings=utf-8
set ambiwidth=double " □や○文字が崩れる問題を解決
scriptencoding utf-8
set bomb
set binary
set ttyfast
set backspace=indent,eol,start
set tabstop=4
set softtabstop=4
set shiftwidth=4
set autoindent " 改行時に前の行のインデントを継続する
set smartindent " 改行時に前の行の構文をチェックし次の行のインデントを増減する
set shiftwidth=4 " smartindentで増減する幅
set expandtab
set splitright
set splitbelow
set hidden
set hlsearch
nnoremap <silent><Esc><Esc> :<C-u>set nohlsearch!<CR>
set whichwrap=b,s,h,l,<,>,[,],~ " カーソルの左右移動で行末から次の行の行頭への移動が可能になる
set cursorline " カーソルラインをハイライト
set termguicolors " more blue color
" 行が折り返し表示されていた場合、行単位ではなく表示行単位でカーソルを移動する
nnoremap j gj
nnoremap k gk
nnoremap <down> gj
nnoremap <up> gk
"カーソルの最終編集位置へ
augroup vimrcEx
au BufRead * if line("'\"") > 0 && line("'\"") <= line("$") |
\ exe "normal g`\"" | endif
augroup END
"----------------------------------------------------------
" カッコ・タグの対応
"----------------------------------------------------------
set showmatch " 括弧の対応関係を一瞬表示する
set matchtime=1 " 0.1秒だけ
"let loaded_matchparen=1 止めるとき
source $VIMRUNTIME/macros/matchit.vim " Vimの「%」を拡張する
"hi MatchParen ctermbg=1"
hi MatchParen term=standout ctermbg=Black ctermfg=LightGrey guibg=Black guifg=LightGrey
set incsearch
set ignorecase
set smartcase
set nobackup
set noswapfile
set fileformats=unix,dos,mac
syntax on
set ruler
set number
set wildmenu " コマンドモードの補完
set history=5000 " 保存するコマンド履歴の数
set gcr=a:blinkon0
set scrolloff=3
set laststatus=2
set showmode " 現在のモードを表示
set showcmd " 打ったコマンドをステータスラインの下に表示
set modeline
set modelines=10
set pumheight=10 "if value is 0 , show menu all
set title
set titleold="Terminal"
set titlestring=%F
set statusline=%F%m%r%h%w%=(%{&ff}/%Y)\ (line\ %l\/%L,\ col\ %c)\
set autoread
set noerrorbells visualbell t_vb=
set clipboard+=unnamed,autoselect
set mouse=a
set whichwrap=b,s,h,l,<,>,[,]
set t_Co=257 " iTerm2など既に256色環境なら無くても良い
syntax enable " 構文に色を付ける
"highlight Pmenu ctermbg=233 ctermfg=241
"highlight PmenuSel ctermbg=233 ctermfg=166
"highlight Search ctermbg=166 ctermfg=233
"highlight Visual ctermbg=166 ctermfg=233
"command #these names are able to change.
command Dir NERDTree
command Vsh vertical terminal
command Run QuickRun
command Sfg setfiletype gnuplot
autocmd BufNewFile,BufRead *.dat setfiletype gnuplot
autocmd BufNewFile,BufRead *.gp setfiletype gnuplot
autocmd BufNewFile,BufRead *.in setfiletype conf
" gnuplot is using # as comment and vi don't check syntax
" autocmd BufNewFile,BufRead *.prm setfiletype gnuplot
" autocmd BufNewFile,BufRead *.txt setfiletype txt
"filetype plugin indent off
" autocmd FileType python setlocal omnifunc=jedi#completions
" this statement is needed
let g:csv_delim=','
filetype plugin indent on
" if set filetype=="csv"
" autocmd setfiletype conf
" endif
"
" autocmd BufReadPost * tab ball " open by tab
" nnoremap tt gt
let &colorcolumn=join(range(81,999),",")
hi ColorColumn ctermbg=235 guibg=#2c2d27
set termguicolors
自分で試したこと
- vimの再インストール (
brew rm vim && brew install vim
) -
DenopsHello
が正しく起動することを確認 (:DenopsHello
->Hello, Denops!
) - vimPlugのアップデート、アップグレード(
:PlugInstall
,:PlugUpdate
,:PlugUpgrade
) - ddc.vimを使用しなければこのエラーは出ませんが、入力補完を使いたいと思いなるべくならこのプラグインを有効にしたい。
0