Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorForrest L Norvell <forrest@npmjs.com>2014-07-23 00:36:56 +0400
committerForrest L Norvell <forrest@npmjs.com>2014-07-23 00:36:56 +0400
commit99fa03b52bdcd3a2e81c75160799dfe0a778ac1a (patch)
tree5e4102dabd9f3f3229e27b278dbca73d040b4280 /node_modules/fstream
parent4c3c77839920e830991e0c229c3c6a855c914d67 (diff)
fstream@0.1.29
Diffstat (limited to 'node_modules/fstream')
-rw-r--r--node_modules/fstream/lib/file-writer.js6
-rw-r--r--node_modules/fstream/package.json29
2 files changed, 27 insertions, 8 deletions
diff --git a/node_modules/fstream/lib/file-writer.js b/node_modules/fstream/lib/file-writer.js
index 681146258..5e9902a63 100644
--- a/node_modules/fstream/lib/file-writer.js
+++ b/node_modules/fstream/lib/file-writer.js
@@ -72,7 +72,11 @@ FileWriter.prototype.write = function (c) {
// allow 2 buffered writes, because otherwise there's just too
// much stop and go bs.
- return ret || (me._stream._queue && me._stream._queue.length <= 2)
+ if (ret === false && me._stream._queue) {
+ return me._stream._queue.length <= 2;
+ } else {
+ return ret;
+ }
}
FileWriter.prototype.end = function (c) {
diff --git a/node_modules/fstream/package.json b/node_modules/fstream/package.json
index fcdda9c65..fdb4976b6 100644
--- a/node_modules/fstream/package.json
+++ b/node_modules/fstream/package.json
@@ -6,7 +6,7 @@
},
"name": "fstream",
"description": "Advanced file system stream things",
- "version": "0.1.28",
+ "version": "0.1.29",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/fstream.git"
@@ -28,14 +28,29 @@
"test": "tap examples/*.js"
},
"license": "BSD",
- "readme": "Like FS streams, but with stat on them, and supporting directories and\nsymbolic links, as well as normal files. Also, you can use this to set\nthe stats on a file, even if you don't change its contents, or to create\na symlink, etc.\n\nSo, for example, you can \"write\" a directory, and it'll call `mkdir`. You\ncan specify a uid and gid, and it'll call `chown`. You can specify a\n`mtime` and `atime`, and it'll call `utimes`. You can call it a symlink\nand provide a `linkpath` and it'll call `symlink`.\n\nNote that it won't automatically resolve symbolic links. So, if you\ncall `fstream.Reader('/some/symlink')` then you'll get an object\nthat stats and then ends immediately (since it has no data). To follow\nsymbolic links, do this: `fstream.Reader({path:'/some/symlink', follow:\ntrue })`.\n\nThere are various checks to make sure that the bytes emitted are the\nsame as the intended size, if the size is set.\n\n## Examples\n\n```javascript\nfstream\n .Writer({ path: \"path/to/file\"\n , mode: 0755\n , size: 6\n })\n .write(\"hello\\n\")\n .end()\n```\n\nThis will create the directories if they're missing, and then write\n`hello\\n` into the file, chmod it to 0755, and assert that 6 bytes have\nbeen written when it's done.\n\n```javascript\nfstream\n .Writer({ path: \"path/to/file\"\n , mode: 0755\n , size: 6\n , flags: \"a\"\n })\n .write(\"hello\\n\")\n .end()\n```\n\nYou can pass flags in, if you want to append to a file.\n\n```javascript\nfstream\n .Writer({ path: \"path/to/symlink\"\n , linkpath: \"./file\"\n , SymbolicLink: true\n , mode: \"0755\" // octal strings supported\n })\n .end()\n```\n\nIf isSymbolicLink is a function, it'll be called, and if it returns\ntrue, then it'll treat it as a symlink. If it's not a function, then\nany truish value will make a symlink, or you can set `type:\n'SymbolicLink'`, which does the same thing.\n\nNote that the linkpath is relative to the symbolic link location, not\nthe parent dir or cwd.\n\n```javascript\nfstream\n .Reader(\"path/to/dir\")\n .pipe(fstream.Writer(\"path/to/other/dir\"))\n```\n\nThis will do like `cp -Rp path/to/dir path/to/other/dir`. If the other\ndir exists and isn't a directory, then it'll emit an error. It'll also\nset the uid, gid, mode, etc. to be identical. In this way, it's more\nlike `rsync -a` than simply a copy.\n",
- "readmeFilename": "README.md",
- "gitHead": "f757159eb6a5198a9ebc6cde1c4c1b9ae8e0d7b2",
+ "gitHead": "aa6679f6fadc46ca83a97f562acde755266bf1bb",
"bugs": {
"url": "https://github.com/isaacs/fstream/issues"
},
"homepage": "https://github.com/isaacs/fstream",
- "_id": "fstream@0.1.28",
- "_shasum": "2b9286f3a646e30075efd0354729361c4b762a29",
- "_from": "fstream@~0.1.27"
+ "_id": "fstream@0.1.29",
+ "_shasum": "34d04023ebc91a9df47bd31ab97e4704b4db413f",
+ "_from": "fstream@0.1.29",
+ "_npmVersion": "1.5.0-alpha-4",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "34d04023ebc91a9df47bd31ab97e4704b4db413f",
+ "tarball": "http://registry.npmjs.org/fstream/-/fstream-0.1.29.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/fstream/-/fstream-0.1.29.tgz"
}