diff options
Diffstat (limited to '.vim/plugins.vim')
| -rw-r--r-- | .vim/plugins.vim | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/.vim/plugins.vim b/.vim/plugins.vim new file mode 100644 index 0000000..a59933f --- /dev/null +++ b/.vim/plugins.vim @@ -0,0 +1,22 @@ +let s:plugin_dir = expand('~/vim/plugged') + + +function! s:ensure(repo) + let name = split(a:repo, '/')[-1] + let path = s:plugin_dir . '/' . name + + if !isdirectory(path) + if !isdirectory(s:plugin_dir) + call mkdir(s:plugin_dir, 'p') + endif + execute '!git clone --depth=1 https://github.com/' . a:repo . ' ' . shellescape(path) + endif + + execute 'set runtimepath+=' . fnameescape(path) +endfunction + +call s:ensure('ghifarit53/tokyonight-vim') +call s:ensure('junegunn/fzf') +call s:ensure('junegunn/fzf.vim') +call s:ensure('itchyny/lightline.vim') + |
