diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2020-05-16 01:25:11 +1200 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2020-05-16 01:29:15 +1200 |
commit | ac26a33542925fe5fa458572e2a0161f3d9c5beb (patch) | |
tree | ad0f2e9c81421d8db07dd4967b80f10a6e1da25a | |
parent | Write out over-engineered path creation function (diff) | |
download | dotfiles-ac26a33542925fe5fa458572e2a0161f3d9c5beb.tar.gz dotfiles-ac26a33542925fe5fa458572e2a0161f3d9c5beb.zip |
Bail from Vim if &runtimepath is empty
Really shouldn't happen, but probably worth catching.
-rw-r--r-- | vim/vimrc | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -113,9 +113,10 @@ endif " first value from the 'runtimepath'. We'll use this later on in the file to " comprehensively match expected paths for vimrc files. " -if &runtimepath !=# '' - let $MYVIM = option#Split(&runtimepath)[0] +if &runtimepath ==# '' + throw 'Empty ''runtimepath''' endif +let $MYVIM = option#Split(&runtimepath)[0] " The next components of the runtime directory that we'll set up here will " make use of the user’s configured XDG base directories: |