Calculate colors_name for snapshots at runtime

This commit is contained in:
Matt Wozniski 2009-03-28 03:29:41 -04:00
parent fe8d4e6acf
commit df73d5e798

View File

@ -771,10 +771,10 @@ function! s:CSApproxSnapshot(file, overwrite)
let lines += [ 'endif' ] let lines += [ 'endif' ]
let lines += [ '' ] let lines += [ '' ]
let lines += [ 'if v:version < 700' ] let lines += [ 'if v:version < 700' ]
let lines += [ ' let g:colors_name = ' . string(fnamemodify(file, ':t:r')) ] let lines += [ ' let g:colors_name = expand("<sfile>:t:r")' ]
let lines += [ ' command! -nargs=+ CSAHi exe "hi" substitute(substitute(<q-args>, "undercurl", "underline", "g"), "guisp\\S\\+", "", "g")' ] let lines += [ ' command! -nargs=+ CSAHi exe "hi" substitute(substitute(<q-args>, "undercurl", "underline", "g"), "guisp\\S\\+", "", "g")' ]
let lines += [ 'else' ] let lines += [ 'else' ]
let lines += [ ' let g:colors_name = ' . string(fnamemodify(file, ':t:r')) ] let lines += [ ' let g:colors_name = expand("<sfile>:t:r")' ]
let lines += [ ' command! -nargs=+ CSAHi exe "hi" <q-args>' ] let lines += [ ' command! -nargs=+ CSAHi exe "hi" <q-args>' ]
let lines += [ 'endif' ] let lines += [ 'endif' ]
let lines += [ '' ] let lines += [ '' ]