Skip to content

Instantly share code, notes, and snippets.

@mranney
Created March 2, 2012 21:15
Show Gist options
  • Save mranney/7a4210446cc6bf666ca8 to your computer and use it in GitHub Desktop.
Save mranney/7a4210446cc6bf666ca8 to your computer and use it in GitHub Desktop.
[root@omega-01 ~]# echo '{"foo": true}' | /usr/bin/json
The "sys" module is now called "util". It should have a similar interface.
{
"foo": true
}
/usr/bin/json:464
process.stdout.flush();
^
TypeError: Object #<WriteStream> has no method 'flush'
at EventEmitter.<anonymous> (/usr/bin/json:464:20)
at EventEmitter.emit (events.js:64:17)
[root@omega-01 ~]# head /usr/bin/json
#!/usr/bin/env node
//
// json -- pipe in your JSON for nicer output and for extracting data bits
//
// See <https://github.com/trentm/json>.
//
var VERSION = "1.4.1";
var sys = require('sys');
[root@omega-01 ~]# node -v
v0.6.11
[root@omega-01 ~]# /usr/bin/node -v
v0.4.9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment