Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

tubesock

1.0.0 • Public • Published

Tubesock

Tubesock is a little utility that pipes stdin to a WebSocket (and back again).

installation

$ npm install -g tubesock

usage

$ tail -f tubes.log | tubesock
ws = new WebSocket('ws://localhost:9999')
ws.onmessage = function () { ... }

options

--port

The port to open the WebSocket server on. Default 9999.

--send-options

The port to open the WebSocket server on. Default true.

custom options

As long as you don't set --send-options to false, any additional options you pass to tubesock will be sent to new client connections.

contributing

Do it!

install

npm i tubesock

Downloadsweekly downloads

1

version

1.0.0

license

MIT

repository

githubgithub

last publish

collaborators

  • avatar