Created
November 30, 2015 14:38
-
-
Save ptaferner/4b33c4137cc0564d4308 to your computer and use it in GitHub Desktop.
CLI script for node modules
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
process.stdin.resume(); | |
process.stdin.setEncoding('utf8'); | |
process.stdin.on('data', function(data) { | |
var pd = require('pretty-data').pd; | |
var xml_min = pd.xmlmin(data,true); | |
process.stdout.write(xml_min); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment