mhinz / vim-startify

:link: The fancy start screen for Vim.
MIT License
5.3k stars 186 forks source link

Problem with loadview with folds #529

Open ArianaAsl opened 2 years ago

ArianaAsl commented 2 years ago

Hi I get the following error when I try to open a file after stratify launch Error detected while processing function startify#open_buffers[6]..18_open_buffer[12]..BufWinLeave Autocommands for "": This only happens when the option "autocmd BufWinLeave mkview is set to load the folds. it doesnt actually have a problem with loading them with autocmd BufWinEnter * silent! loadview. So if I mkview manually it would be fine but its nice to keep it automated. Any help is much appreciated. I'm using the latest vim version on linux from the terminal btw. My startify settings:

 let g:startify_custom_header =
       \ startify#pad(split(system('figlet -w 100 Vim is Power'), '\n'))
"Incase you are insane and want to open a new tab with Goyo enabled
 autocmd BufEnter *
       \ if !exists('t:startify_new_tab') && empty(expand('%')) && !exists('t:goyo_master') |
       \   let t:startify_new_tab = 1 |
       \   Startify |
       \ endif
"Bookmarks. Syntax is clear.add yours
let g:startify_bookmarks = [ {'I': '~/i3/i3/config'},{'L': '~/.blerc'},{'Z': '~/.zshrc'},{'B': '~/.bashrc'},{'V': '~/.vimrc'}]
    let g:startify_lists = [
          \ { 'type': 'bookmarks', 'header': ['   Bookmarks']      },
          \ { 'type': 'files',     'header': ['   Recent']            },
          \ { 'type': 'sessions',  'header': ['   Sessions']       },
          \ { 'type': 'commands',  'header': ['   Commands']       },
          \ ]
"cant tell wtf it does so its commented
" \ { 'type': 'dir',       'header': ['   MRU '. getcwd()] },

hi StartifyBracket ctermfg=240
hi StartifyFile    ctermfg=147
hi StartifyFooter  ctermfg=240
hi StartifyHeader  ctermfg=114
hi StartifyNumber  ctermfg=215
hi StartifyPath    ctermfg=245
hi StartifySlash   ctermfg=240
hi StartifySpecial ctermfg=240