diff options
author | Forrest L Norvell <forrest@npmjs.com> | 2015-06-19 09:51:28 +0300 |
---|---|---|
committer | Forrest L Norvell <forrest@npmjs.com> | 2015-06-19 09:51:28 +0300 |
commit | df894930f2716adac28740b29b2e863170919990 (patch) | |
tree | 19d8ed438b9f259ac3d0a51d512a776e666004e1 /node_modules/fstream/package.json | |
parent | 974404934758124aa8ae5b54f7d5257c3bd6b588 (diff) |
fstream@1.0.7
Standardized and with new tap.
Contributed by @isaacs, unsurprisingly.
PR-URL: https://github.com/npm/fstream/pull/44
Diffstat (limited to 'node_modules/fstream/package.json')
-rw-r--r-- | node_modules/fstream/package.json | 42 |
1 files changed, 9 insertions, 33 deletions
diff --git a/node_modules/fstream/package.json b/node_modules/fstream/package.json index aa6bc1cf3..0109d940c 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": "1.0.6", + "version": "1.0.7", "repository": { "type": "git", "url": "git://github.com/isaacs/fstream.git" @@ -22,45 +22,21 @@ "rimraf": "2" }, "devDependencies": { - "tap": "0", - "standard": "^2.3.2" + "standard": "^4.0.0", + "tap": "^1.2.0" }, "scripts": { "test": "standard && tap examples/*.js" }, "license": "ISC", - "gitHead": "e0c0024379c5a94ca228d232e2794b6ffb0d3caf", + "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": "586e8efc1cf77883f6c22fc32a7cb38f0eb88911", "bugs": { "url": "https://github.com/isaacs/fstream/issues" }, "homepage": "https://github.com/isaacs/fstream#readme", - "_id": "fstream@1.0.6", - "_shasum": "817e50312fb4ed90da865c8eb5ecd1d1d7aed0ec", - "_from": "fstream@>=1.0.6 <1.1.0", - "_npmVersion": "2.9.0", - "_nodeVersion": "2.0.0", - "_npmUser": { - "name": "iarna", - "email": "me@re-becca.org" - }, - "maintainers": [ - { - "name": "isaacs", - "email": "isaacs@npmjs.com" - }, - { - "name": "othiym23", - "email": "ogd@aoaioxxysz.net" - }, - { - "name": "iarna", - "email": "me@re-becca.org" - } - ], - "dist": { - "shasum": "817e50312fb4ed90da865c8eb5ecd1d1d7aed0ec", - "tarball": "http://registry.npmjs.org/fstream/-/fstream-1.0.6.tgz" - }, - "directories": {}, - "_resolved": "https://registry.npmjs.org/fstream/-/fstream-1.0.6.tgz" + "_id": "fstream@1.0.7", + "_shasum": "455a1aa1d46077668d95b6d27838e1b1daa78c78", + "_from": "fstream@>=1.0.7 <1.1.0" } |