mirror of
https://github.com/junegunn/vim-plug.git
synced 2024-12-23 20:45:31 -07:00
Fix Ruby installer on Vim 8.0.0036 (#538)
This could be a bug of Vim, but the new method should be safer in the long run though it doesn't work on Ruby 1.8.
This commit is contained in:
parent
01e4e9170a
commit
c66e264d41
5
plug.vim
5
plug.vim
@ -1796,9 +1796,8 @@ function! s:update_ruby()
|
|||||||
main = Thread.current
|
main = Thread.current
|
||||||
threads = []
|
threads = []
|
||||||
watcher = Thread.new {
|
watcher = Thread.new {
|
||||||
while VIM::evaluate('getchar(1)')
|
require 'io/console' # >= Ruby 1.9
|
||||||
sleep 0.1
|
nil until IO.console.getch == 3.chr
|
||||||
end
|
|
||||||
mtx.synchronize do
|
mtx.synchronize do
|
||||||
running = false
|
running = false
|
||||||
threads.each { |t| t.raise Interrupt }
|
threads.each { |t| t.raise Interrupt }
|
||||||
|
Loading…
Reference in New Issue
Block a user