diff options
author | Tom Ryder <tom@sanctum.geek.nz> | 2019-12-21 14:29:07 +1300 |
---|---|---|
committer | Tom Ryder <tom@sanctum.geek.nz> | 2019-12-21 14:29:07 +1300 |
commit | 91ef82841ce797aee6a06566f0edddc064656822 (patch) | |
tree | a53bb29054d991fcba8cfa66ca592202624ae815 | |
parent | Make a pattern stricter for #has() (diff) | |
download | dotfiles-91ef82841ce797aee6a06566f0edddc064656822.tar.gz dotfiles-91ef82841ce797aee6a06566f0edddc064656822.zip |
Revert "Delete unused autoload function"
This reverts commit e43249fbdf9b4a8a28c53271e832676ed5ef1c1e.
-rw-r--r-- | vim/autoload/path.vim | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/vim/autoload/path.vim b/vim/autoload/path.vim new file mode 100644 index 00000000..83102138 --- /dev/null +++ b/vim/autoload/path.vim @@ -0,0 +1,12 @@ +function! path#Create(name, ...) abort + if a:0 > 2 + echoerr 'Too many arguments' + endif + if isdirectory(a:name) + return 1 + endif + let name = a:name + let path = 'p' + let prot = a:0 == 1 && a:1 ? 0700 : 0755 + return mkdir(name, path, prot) +endfunction |