npm: Upgrade to 1.3.17
[platform/upstream/nodejs.git] / deps / npm / node_modules / fstream / package.json
1 {
2   "author": {
3     "name": "Isaac Z. Schlueter",
4     "email": "i@izs.me",
5     "url": "http://blog.izs.me/"
6   },
7   "name": "fstream",
8   "description": "Advanced file system stream things",
9   "version": "0.1.25",
10   "repository": {
11     "type": "git",
12     "url": "git://github.com/isaacs/fstream.git"
13   },
14   "main": "fstream.js",
15   "engines": {
16     "node": ">=0.6"
17   },
18   "dependencies": {
19     "rimraf": "2",
20     "mkdirp": "0.3",
21     "graceful-fs": "~2.0.0",
22     "inherits": "~2.0.0"
23   },
24   "devDependencies": {
25     "tap": ""
26   },
27   "scripts": {
28     "test": "tap examples/*.js"
29   },
30   "license": "BSD",
31   "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",
32   "readmeFilename": "README.md",
33   "bugs": {
34     "url": "https://github.com/isaacs/fstream/issues"
35   },
36   "homepage": "https://github.com/isaacs/fstream",
37   "_id": "fstream@0.1.25",
38   "dist": {
39     "shasum": "deef2db7c7898357c2b37202212a9e5b36abc732"
40   },
41   "_from": "fstream@0.1.25",
42   "_resolved": "https://registry.npmjs.org/fstream/-/fstream-0.1.25.tgz"
43 }