Compare commits
3 Commits
c63c5b3ae6
...
3f48f65ca5
Author | SHA1 | Date |
---|---|---|
pegasust | 3f48f65ca5 | |
pegasust | 7c7aacafb2 | |
pegasust | 4117852cae |
|
@ -56,16 +56,12 @@ vim.keymap.set('n', '<leader>wq', '<cmd>TroubleToggle workspace_diagnostics<cr>'
|
||||||
-- vim-plug
|
-- vim-plug
|
||||||
local data_dir = vim.fn.stdpath('data')
|
local data_dir = vim.fn.stdpath('data')
|
||||||
vim.cmd([[
|
vim.cmd([[
|
||||||
" Install vim-plug if not found
|
let data_dir = has('nvim') ? stdpath('data') . '/site' : '~/.vim'
|
||||||
if empty(glob('~/.vim/autoload/plug.vim'))
|
if empty(glob(data_dir . '/autoload/plug.vim'))
|
||||||
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs
|
silent execute '!curl -fLo '.data_dir.'/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
|
||||||
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Run PlugInstall if there are missing plugins
|
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
|
||||||
autocmd VimEnter * if len(filter(values(g:plugs), '!isdirectory(v:val.dir)'))
|
|
||||||
\| PlugInstall --sync | source $MYVIMRC
|
|
||||||
\| endif
|
|
||||||
]])
|
]])
|
||||||
|
|
||||||
local Plug = vim.fn['plug#']
|
local Plug = vim.fn['plug#']
|
||||||
|
|
Loading…
Reference in New Issue