From ec9e4a2aa28bd9e20a7d1e14e74952462bb49a4f Mon Sep 17 00:00:00 2001 From: mattn Date: Fri, 13 Apr 2012 10:27:23 +0900 Subject: user configuration should be prior to default template directory. --- autoload/sonictemplate.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'autoload') diff --git a/autoload/sonictemplate.vim b/autoload/sonictemplate.vim index 033524a..04bfd22 100644 --- a/autoload/sonictemplate.vim +++ b/autoload/sonictemplate.vim @@ -6,7 +6,7 @@ let s:save_cpo = &cpo set cpo&vim -let s:tmpldir = [expand(':p:h:h') . '/template/'] +let s:tmpldir = [] if exists('g:sonictemplate_vim_template_dir') if type(g:sonictemplate_vim_template_dir) == 3 let s:tmpldir += map(g:sonictemplate_vim_template_dir, 'fnamemodify(expand(v:val), ":p")') @@ -14,6 +14,7 @@ if exists('g:sonictemplate_vim_template_dir') call add(s:tmpldir, fnamemodify(expand(g:sonictemplate_vim_template_dir), ":p")) endif endif +call add(s:tmpldir, expand(':p:h:h') . '/template/') function! sonictemplate#select(mode) abort let name = input(':Template ', '', 'customlist,sonictemplate#complete') -- cgit v1.2.3-54-g00ecf