wincent / vim-clipper

Clipper integration for Vim
BSD 2-Clause "Simplified" License
43 stars 5 forks source link

Clip command hangs #1

Closed paulhybryant closed 7 years ago

paulhybryant commented 8 years ago

Somehow the nc command now waits indefinitely after sending the content (it does not in the past, not sure why).

changing nc localhost to nc -c localhost 8377 (or nc -q 0 localhost 8377 depending on the netcat version you have) works.

00dani commented 7 years ago

I figured out what the difference is: the nc that ships with MacOS is an old fork of OpenBSD netcat, while the nc available in Homebrew is the latest version of GNU netcat, 0.7.1. Amusingly, GNU netcat's latest release is actually older than Apple's fork.

The easiest way to get a modern netcat is to install the Homebrew formula nmap, which also ships with a netcat command called ncat:

$ brew install nmap
$ ls | ncat -4 localhost 8377

(The -4 is needed by default since Clipper only listens on your IPv4 address, and nmap's netcat supports IPv6 too.)

wincent commented 7 years ago

Hm. We should listen on IPv6 loopback too.