mirror of
https://github.com/SpaceVim/SpaceVim.git
synced 2025-01-23 10:20:05 +08:00
fix(config): handle error in local config
This commit is contained in:
parent
58874d8b21
commit
b443539fb3
@ -198,7 +198,13 @@ function! SpaceVim#autocmds#VimEnter() abort
|
||||
|
||||
if !filereadable('.SpaceVim.d/init.toml') && filereadable('.SpaceVim.d/init.vim')
|
||||
call SpaceVim#logger#info('loading local conf: .SpaceVim.d/init.vim')
|
||||
exe 'source .SpaceVim.d/init.vim'
|
||||
try
|
||||
exe 'source .SpaceVim.d/init.vim'
|
||||
catch
|
||||
call SpaceVim#logger#error('Error occurred while loading the local configuration')
|
||||
call SpaceVim#logger#error(' exception: ' . v:exception)
|
||||
call SpaceVim#logger#error(' throwpoint: ' . v:throwpoint)
|
||||
endtry
|
||||
call SpaceVim#logger#info('finished loading local conf')
|
||||
endif
|
||||
endfunction
|
||||
|
Loading…
Reference in New Issue
Block a user