3 ms·
We need a generic pipe for internet services. Yes there is IFTTT and open-source clones, but they are not generically useful like the unix pipe on the command
by andyl 14y ago
We need a generic pipe for internet services. Yes there is IFTTT and open-source clones, but they are not generically useful like the unix pipe on the command line.
- hucker 14y agocurl http://example.com/some/api/resource/json | sort | uniq | whatever?
- tingletech 14y agowhat good is it going to do to sort JSON? You need something like http://stedolan.github.com/jq/ http://stedolan.github.com/jq/
- andyl 14y agojq - great tip - thanks for that!
- beachstartup 14y agonetcat comes pretty close...
- hhw 14y agotcputils from Debian does precisely that, allowing you to extend a UNIX pipe over a TCP connection. It's not generally available as a package in other distros, but you can easily grab the source from Debian and compile it yourself. Consequently, tarballing to stdout and piping over tcputils is by far the fastest and most efficient way to send a large number of files over a network.
- nathan7 14y agoBash actually supports /dev/tcp/HOSTNAME/PORT for this kind of thing. Ironically, that's disabled in the Debian bash package.