X-Git-Url: https://oss.titaniummirror.com/gitweb?a=blobdiff_plain;f=vim%2Fvimrc;h=a670f8625513ff8625a5c62e2e51dfce9bf11e17;hb=3caeda4578056051840d4b35ab9ac02e4f4f2601;hp=68d687ef6d73e46999cac6e705f640799e3e4b52;hpb=b4b5b5dcc5cff6d35255cf9230426ba1a07c2b8e;p=smckown%2Fdotfiles.git diff --git a/vim/vimrc b/vim/vimrc index 68d687e..a670f86 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -90,9 +90,7 @@ endif " Setup swap/backup/undo " Note that as of vim 7.4, backupdir // will not expand backup files to a full " path as is the case with directory and undodir. -let s:dir = expand(has('win32') ? '~/Application Data/Vim' : has('mac') ? - \ '~/Library/Vim' : '~/.local/share/vim') -execute 'set directory^=' . s:dir . '/swap//' +let s:dir = expand(has('win32') ? '$HOME/vimfiles' : '$HOME/.vim') if !isdirectory(s:dir . '/') call mkdir(s:dir) endif @@ -105,6 +103,7 @@ endif if !isdirectory(s:dir . '/undo/') call mkdir(s:dir . '/undo') endif +execute 'set directory^=' . s:dir . '/swap//' if isdirectory(s:dir . '/backup/') execute 'set backupdir=' . s:dir . '/backup//' set backup