1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-02-03 00:20:05 +08:00

Fix compile info (#3329)

This commit is contained in:
Wang Shidong 2020-02-03 20:05:30 +08:00 committed by GitHub
parent 3178aefbdd
commit 65459ed042
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -98,8 +98,13 @@ function! s:async_run(runner) abort
let usestdin = 0
let compile_cmd = substitute(printf(a:runner[0], bufname('%')), '#TEMP#', s:target, 'g')
endif
if type(compile_cmd) == type([])
let compile_cmd_info = string(compile_cmd + (usestdin ? ['STDIN'] : []))
else
let compile_cmd_info = compile_cmd . (usestdin ? ' STDIN' : '')
endif
call s:BUFFER.buf_set_lines(s:bufnr, s:lines , s:lines + 3, 0, [
\ '[Compile] ' . compile_cmd . (usestdin ? ' STDIN' : ''),
\ '[Compile] ' . compile_cmd_info,
\ '[Running] ' . s:target,
\ '',
\ repeat('-', 20)])