Bail out if Unix socket already exists

References https://github.com/mhinz/neovim-remote/pull/159
pull/179/head
Marco Hinz 2 years ago
parent 1aa1651c33
commit 3130be19a9
No known key found for this signature in database

@ -422,6 +422,15 @@ def main(argv=sys.argv, env=os.environ):
nvr.attach()
if not nvr.server:
if os.path.exists(nvr.address):
print(textwrap.dedent(f'''
[!] A file {nvr.address} exists, but we failed to attach to it.
Is it a Unix domain socket? Either remove that file and try
again or choose another address with --servername.
'''))
return
silent = options.remote_silent or options.remote_wait_silent or options.remote_tab_silent or options.remote_tab_wait_silent or options.s
if not silent:
show_message(address)

Loading…
Cancel
Save