diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-13 22:29:23 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2017-11-13 22:29:23 +1300 |
commit | 9e6c1a55d4b00aa114393024421b564f56b7336d (patch) | |
tree | 8c6ee99709c478a3534dfb7ee5d4bfb688b5511c /vim/plugin/auto_undodir.vim | |
parent | Merge branch 'feature/trailing-space' into develop (diff) | |
parent | Check for shellescape() function before using it (diff) | |
download | dotfiles-9e6c1a55d4b00aa114393024421b564f56b7336d.tar.gz dotfiles-9e6c1a55d4b00aa114393024421b564f56b7336d.zip |
Merge branch 'feature/vim-plug' into develop
* feature/vim-plug:
Check for shellescape() function before using it
Diffstat (limited to 'vim/plugin/auto_undodir.vim')
-rw-r--r-- | vim/plugin/auto_undodir.vim | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/vim/plugin/auto_undodir.vim b/vim/plugin/auto_undodir.vim index 8e81fde6..0cd54cd0 100644 --- a/vim/plugin/auto_undodir.vim +++ b/vim/plugin/auto_undodir.vim @@ -35,12 +35,14 @@ if !isdirectory(expand(s:undodir)) " Failing that, use an OS-dependent command " (Fortunately, Unix and Windows are the only OS types in the world) - elseif has('unix') - silent! execute '!mkdir -m 0700 -p ' - \ . shellescape(expand(s:undodir)) - elseif has('win32') || has('win64') - silent! execute '!mkdir ' - \ . shellescape(expand(s:undodir)) + elseif has('*shellescape') + elseif has('unix') + silent! execute '!mkdir -m 0700 -p ' + \ . shellescape(expand(s:undodir)) + elseif has('win32') || has('win64') + silent! execute '!mkdir ' + \ . shellescape(expand(s:undodir)) + endif endif endif |