From f90594bb9add21422b49b5a3630339bd53670c04 Mon Sep 17 00:00:00 2001 From: Marco Hinz Date: Thu, 17 Mar 2016 11:44:26 +0100 Subject: [PATCH] Eval g:startify_custom_header if it's a string --- autoload/startify.vim | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/autoload/startify.vim b/autoload/startify.vim index 260a5e6..4c2fc26 100644 --- a/autoload/startify.vim +++ b/autoload/startify.vim @@ -68,9 +68,15 @@ function! startify#insane_in_the_membrane() abort endif " Must be global so that it can be read by syntax/startify.vim. - let g:startify_header = exists('g:startify_custom_header') - \ ? copy(g:startify_custom_header) - \ : startify#fortune#cowsay() + if exists('g:startify_custom_header') + if type(g:startify_custom_header) == type([]) + let g:startify_header = copy(g:startify_custom_header) + else + let g:startify_header = eval(g:startify_custom_header) + endif + else + let g:startify_header = startify#fortune#cowsay() + endif let g:startify_header += [''] " add blank line call append('$', g:startify_header)