Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using netcat or socat to connect to a TCP LSP server #801

Closed
Rubonnek opened this issue Apr 25, 2020 · 2 comments
Closed

Using netcat or socat to connect to a TCP LSP server #801

Rubonnek opened this issue Apr 25, 2020 · 2 comments

Comments

@Rubonnek
Copy link

Rubonnek commented Apr 25, 2020

Hello,

I'm trying to connect to the LSP server of the Godot Game Engine which only communicates over TCP, so I figured I could use netcat or socat to get around that.

I tried this, but I don't see any packets going through the loopback device:

Here's what I tried:

if executable('godot_server')
	augroup lsp_godot
		autocmd!
		autocmd User lsp_setup call lsp#register_server({
					\ 'name': 'godot_server',
					\ 'cmd': {server_info->['nc', '127.0.0.1', '6008']},
					\ 'whitelist': ['gd'],
					\ 'initialization_options': {
					\   'vimruntime': $VIMRUNTIME,
					\   'runtimepath': &rtp,
					\ }})
	augroup end
	autocmd FileType gd setlocal omnifunc=lsp#complete
endif

The godot_server exists and I see it getting registered:

Fri 24 Apr 2020 08:53:30 PM EDT:["lsp#register_server","server registered","godot_server"]

I just don't see packets passing through the loopback device.

@Rubonnek
Copy link
Author

Welp, nevermind. I got it to work:

if executable('godot_server')
	augroup lsp_godot
		autocmd!
		autocmd User lsp_setup call lsp#register_server({
					\ 'name': 'godot_server',
					\ 'cmd': {server_info->['nc', '127.0.0.1', '6008']},
					\ 'whitelist': ['gd', 'gdscript3'],
					\ })
	augroup end
endif

@mattn
Copy link
Collaborator

mattn commented Dec 31, 2020

Now vim-lsp support tcp feature. #985

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants