2 Commits

Author SHA1 Message Date
Zach Carter
cfda950c3c version 1.1.1 2011-06-04 10:32:18 -04:00
Zach Carter
ae5025e5ac Fix overwriting bug. 2011-06-04 10:32:04 -04:00
2 changed files with 4 additions and 4 deletions

View File

@@ -50,11 +50,11 @@ function main (args) {
var source = '';
if (options.file) {
var path = require('path').join(process.cwd(), options.file);
source = fs.readFileSync(path, "utf8");
source = parse(fs.readFileSync(path, "utf8"));
if (options.inplace) {
fs.writeSync(fs.openSync(path,'w+'), parse(source), 0, "utf8");
fs.writeSync(fs.openSync(path,'w+'), source, 0, "utf8");
} else {
sys.puts(parse(source));
sys.puts(source);
}
} else {
var stdin = process.openStdin();

View File

@@ -8,7 +8,7 @@
"lint",
"jsonlint"
],
"version": "1.1.0",
"version": "1.1.1",
"preferGlobal": true,
"repository": {
"type": "git",