package.json 3.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. {
  2. "name": "mkdirp",
  3. "description": "Recursively mkdir, like `mkdir -p`",
  4. "version": "0.5.0",
  5. "author": {
  6. "name": "James Halliday",
  7. "email": "mail@substack.net",
  8. "url": "http://substack.net"
  9. },
  10. "main": "./index",
  11. "keywords": [
  12. "mkdir",
  13. "directory"
  14. ],
  15. "repository": {
  16. "type": "git",
  17. "url": "https://github.com/substack/node-mkdirp.git"
  18. },
  19. "scripts": {
  20. "test": "tap test/*.js"
  21. },
  22. "dependencies": {
  23. "minimist": "0.0.8"
  24. },
  25. "devDependencies": {
  26. "tap": "~0.4.0",
  27. "mock-fs": "~2.2.0"
  28. },
  29. "bin": {
  30. "mkdirp": "bin/cmd.js"
  31. },
  32. "license": "MIT",
  33. "readme": "# mkdirp\n\nLike `mkdir -p`, but in node.js!\n\n[![build status](https://secure.travis-ci.org/substack/node-mkdirp.png)](http://travis-ci.org/substack/node-mkdirp)\n\n# example\n\n## pow.js\n\n```js\nvar mkdirp = require('mkdirp');\n \nmkdirp('/tmp/foo/bar/baz', function (err) {\n if (err) console.error(err)\n else console.log('pow!')\n});\n```\n\nOutput\n\n```\npow!\n```\n\nAnd now /tmp/foo/bar/baz exists, huzzah!\n\n# methods\n\n```js\nvar mkdirp = require('mkdirp');\n```\n\n## mkdirp(dir, opts, cb)\n\nCreate a new directory and any necessary subdirectories at `dir` with octal\npermission string `opts.mode`. If `opts` is a non-object, it will be treated as\nthe `opts.mode`.\n\nIf `opts.mode` isn't specified, it defaults to `0777 & (~process.umask())`.\n\n`cb(err, made)` fires with the error or the first directory `made`\nthat had to be created, if any.\n\nYou can optionally pass in an alternate `fs` implementation by passing in\n`opts.fs`. Your implementation should have `opts.fs.mkdir(path, mode, cb)` and\n`opts.fs.stat(path, cb)`.\n\n## mkdirp.sync(dir, opts)\n\nSynchronously create a new directory and any necessary subdirectories at `dir`\nwith octal permission string `opts.mode`. If `opts` is a non-object, it will be\ntreated as the `opts.mode`.\n\nIf `opts.mode` isn't specified, it defaults to `0777 & (~process.umask())`.\n\nReturns the first directory that had to be created, if any.\n\nYou can optionally pass in an alternate `fs` implementation by passing in\n`opts.fs`. Your implementation should have `opts.fs.mkdirSync(path, mode)` and\n`opts.fs.statSync(path)`.\n\n# usage\n\nThis package also ships with a `mkdirp` command.\n\n```\nusage: mkdirp [DIR1,DIR2..] {OPTIONS}\n\n Create each supplied directory including any necessary parent directories that\n don't yet exist.\n \n If the directory already exists, do nothing.\n\nOPTIONS are:\n\n -m, --mode If a directory needs to be created, set the mode as an octal\n permission string.\n\n```\n\n# install\n\nWith [npm](http://npmjs.org) do:\n\n```\nnpm install mkdirp\n```\n\nto get the library, or\n\n```\nnpm install -g mkdirp\n```\n\nto get the command.\n\n# license\n\nMIT\n",
  34. "readmeFilename": "readme.markdown",
  35. "bugs": {
  36. "url": "https://github.com/substack/node-mkdirp/issues"
  37. },
  38. "homepage": "https://github.com/substack/node-mkdirp",
  39. "_id": "mkdirp@0.5.0",
  40. "_shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12",
  41. "_from": "mkdirp@0.5.0",
  42. "_resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz"
  43. }