File tree Expand file tree Collapse file tree 3 files changed +13
-2
lines changed Expand file tree Collapse file tree 3 files changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -785,11 +785,21 @@ function! LanguageClient#binaryPath() abort
785785 return l: path . l: filename
786786endfunction
787787
788+ function ! LanguageClient#installBinaries ()
789+ let l: installsh = ' cd ' . s: root . ' && ./install.sh'
790+ let l: output = split (system (l: installsh ), ' \n' )
791+ for l: line in l: output
792+ echomsg l: line
793+ endfor
794+ echomsg " Success."
795+ endfunction
796+
788797function ! s: Launch () abort
789798 let l: binpath = LanguageClient#binaryPath ()
790799
791800 if executable (l: binpath ) != 1
792- call s: Echoerr (' LanguageClient: binary (' . l: binpath . ' ) doesn'' t exists! Please check installation guide.' )
801+ call s: Echoerr (' LanguageClient: binary (' . l: binpath . ' ) doesn'' t exists!' )
802+ call s: Echoerr (' Run :LanguageClientInstallBinaries or check installation guide.' )
793803 return 0
794804 endif
795805
Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ arch=$(uname -sm)
1313
1414try_curl () {
1515 command -v curl > /dev/null && \
16- curl --fail --location " $1 " --output bin/$name
16+ curl --fail --silent --show-error -- location " $1 " --output bin/$name
1717}
1818
1919try_wget () {
Original file line number Diff line number Diff line change @@ -156,6 +156,7 @@ endfunction
156156
157157command ! -nargs =* LanguageClientStart :call LanguageClient#startServer (<f-args> )
158158command ! LanguageClientStop call LanguageClient#shutdown ()
159+ command ! LanguageClientInstallBinaries :call LanguageClient#installBinaries ()
159160
160161function ! s: OnBufEnter ()
161162 if ! LanguageClient#HasCommand (&filetype )
You can’t perform that action at this time.
0 commit comments