mirror of
https://github.com/dense-analysis/ale.git
synced 2026-05-17 13:59:47 +08:00
Only set the unnamed register at the end of :ALEInfoToClipboard
This fixes performance problems in Neovim, where every character results in spawning a new clipboard-tool process. Behaviour is not similarly pathological in Vim, but it still results in an unnecessary amount of register churn.
This commit is contained in:
@@ -237,10 +237,11 @@ function! ale#debugging#Info() abort
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! ale#debugging#InfoToClipboard() abort
|
function! ale#debugging#InfoToClipboard() abort
|
||||||
redir @+>
|
redir => l:output
|
||||||
silent call ale#debugging#Info()
|
silent call ale#debugging#Info()
|
||||||
redir END
|
redir END
|
||||||
|
|
||||||
|
let @+ = l:output
|
||||||
call s:Echo('ALEInfo copied to your clipboard')
|
call s:Echo('ALEInfo copied to your clipboard')
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user