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