Merge pull request #500 from svermeulen/OmnisharpAutoStopOption
Added option to control whether YCM should auto-stop the omnisharp server upon leaving Vim or leave it running.
This commit is contained in:
commit
029c4a6350
@ -850,6 +850,15 @@ Default: `1`
|
|||||||
|
|
||||||
let g:ycm_auto_start_csharp_server = 1
|
let g:ycm_auto_start_csharp_server = 1
|
||||||
|
|
||||||
|
### The `g:ycm_auto_stop_csharp_server` option
|
||||||
|
|
||||||
|
When set to `1`, the OmniSharp server will be automatically stopped upon
|
||||||
|
closing vim.
|
||||||
|
|
||||||
|
Default: `1`
|
||||||
|
|
||||||
|
let g:ycm_auto_stop_csharp_server = 1
|
||||||
|
|
||||||
### The `g:ycm_add_preview_to_completeopt` option
|
### The `g:ycm_add_preview_to_completeopt` option
|
||||||
|
|
||||||
When this option is set to `1`, YCM will add the `preview` string to Vim's
|
When this option is set to `1`, YCM will add the `preview` string to Vim's
|
||||||
|
@ -154,6 +154,9 @@ let g:ycm_cache_omnifunc =
|
|||||||
let g:ycm_auto_start_csharp_server =
|
let g:ycm_auto_start_csharp_server =
|
||||||
\ get( g:, 'ycm_auto_start_csharp_server', 1 )
|
\ get( g:, 'ycm_auto_start_csharp_server', 1 )
|
||||||
|
|
||||||
|
let g:ycm_auto_stop_csharp_server =
|
||||||
|
\ get( g:, 'ycm_auto_stop_csharp_server', 1 )
|
||||||
|
|
||||||
let g:ycm_csharp_server_port =
|
let g:ycm_csharp_server_port =
|
||||||
\ get( g:, 'ycm_csharp_server_port', 2000 )
|
\ get( g:, 'ycm_csharp_server_port', 2000 )
|
||||||
|
|
||||||
|
@ -50,7 +50,7 @@ class CsharpCompleter( ThreadedCompleter ):
|
|||||||
|
|
||||||
|
|
||||||
def OnVimLeave( self ):
|
def OnVimLeave( self ):
|
||||||
if self._ServerIsRunning():
|
if vimsupport.GetBoolValue( 'g:ycm_auto_stop_csharp_server' ) and self._ServerIsRunning():
|
||||||
self._StopServer()
|
self._StopServer()
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user