mirror of
https://github.com/ItsDrike/dotfiles.git
synced 2024-12-26 13:14:35 +00:00
Use XDG locations with fallback
This commit is contained in:
parent
713ad7301e
commit
fd85f2ccff
|
@ -1,8 +1,8 @@
|
|||
" Install plugins automatically
|
||||
if ! filereadable(system('echo -n "${HOME}/.config/nvim/autoload/plug.vim"'))
|
||||
if ! filereadable(system('echo -n "${XDG_CONFIG_HOME:-$HOME/.config}/nvim/autoload/plug.vim"'))
|
||||
echo "Downloading junegunn/vim-plug to manage plugins..."
|
||||
silent !mkdir -p ~/.config/nvim/autoload
|
||||
silent !curl "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" > ~/.config/nvim/autoload/plug.vim
|
||||
silent !mkdir -p ${XDG_CONFIG_HOME:-$HOME/.config}/nvim/autoload/
|
||||
silent !curl "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" > ${XDG_CONFIG_HOME:-$HOME/.config}/nvim/autoload/plug.vim
|
||||
autocmd VimEnter * PlugInstall
|
||||
endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue