{ "_id": "commondir", "_rev": "17-56fbe9608f6ae3be1a2fd2264e939689", "name": "commondir", "description": "compute the closest common parent for file paths", "dist-tags": { "latest": "1.0.1" }, "versions": { "0.0.0": { "name": "commondir", "version": "0.0.0", "description": "Compute the closest common parent for file paths", "main": "index.js", "directories": { "lib": ".", "example": "example", "test": "test" }, "dependencies": {}, "devDependencies": { "expresso": "0.7.x" }, "scripts": { "test": "expresso" }, "repository": { "type": "git", "url": "git://github.com/substack/node-commondir.git" }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "license": "MIT/X11", "engine": { "node": ">=0.4" }, "_id": "commondir@0.0.0", "engines": { "node": "*" }, "_engineSupported": true, "_npmVersion": "1.0.10", "_nodeVersion": "v0.5.0-pre", "_defaultsLoaded": true, "dist": { "shasum": "25fb9c47fa486f81ddf74d6ef061fec59e6260ed", "tarball": "https://registry.npmjs.org/commondir/-/commondir-0.0.0.tgz" } }, "0.0.1": { "name": "commondir", "version": "0.0.1", "description": "Compute the closest common parent for file paths", "main": "index.js", "directories": { "lib": ".", "example": "example", "test": "test" }, "dependencies": {}, "devDependencies": { "expresso": "0.7.x" }, "scripts": { "test": "expresso" }, "repository": { "type": "git", "url": "git://github.com/substack/node-commondir.git" }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "license": "MIT/X11", "engine": { "node": ">=0.4" }, "_npmUser": { "name": "substack", "email": "mail@substack.net" }, "_id": "commondir@0.0.1", "engines": { "node": "*" }, "_engineSupported": true, "_npmVersion": "1.0.101", "_nodeVersion": "v0.4.12", "_defaultsLoaded": true, "dist": { "shasum": "89f00fdcd51b519c578733fec563e6a6da7f5be2", "tarball": "https://registry.npmjs.org/commondir/-/commondir-0.0.1.tgz" }, "maintainers": [ { "name": "substack", "email": "mail@substack.net" } ] }, "0.0.2": { "name": "commondir", "version": "0.0.2", "description": "compute the closest common parent for file paths", "main": "index.js", "dependencies": {}, "devDependencies": { "tape": "^3.5.0" }, "scripts": { "test": "tape test/*.js" }, "repository": { "type": "git", "url": "http://github.com/substack/node-commondir.git" }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "license": "MIT/X11", "engine": { "node": ">=0.4" }, "gitHead": "089fac70cf240745ecde80d02e4193080ce4c5a3", "bugs": { "url": "https://github.com/substack/node-commondir/issues" }, "homepage": "https://github.com/substack/node-commondir", "_id": "commondir@0.0.2", "_shasum": "c49c8880c6fe96844bb3525dd2e7314050c389ee", "_from": ".", "_npmVersion": "2.3.0", "_nodeVersion": "0.12.0", "_npmUser": { "name": "substack", "email": "mail@substack.net" }, "maintainers": [ { "name": "substack", "email": "mail@substack.net" } ], "dist": { "shasum": "c49c8880c6fe96844bb3525dd2e7314050c389ee", "tarball": "https://registry.npmjs.org/commondir/-/commondir-0.0.2.tgz" }, "directories": {} }, "1.0.0": { "name": "commondir", "version": "1.0.0", "description": "compute the closest common parent for file paths", "main": "index.js", "dependencies": {}, "devDependencies": { "tape": "^3.5.0" }, "scripts": { "test": "tape test/*.js" }, "repository": { "type": "git", "url": "http://github.com/substack/node-commondir.git" }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "license": "MIT/X11", "engine": { "node": ">=0.4" }, "gitHead": "b0033272cd882d60c05896d290fddfa716931e5d", "bugs": { "url": "https://github.com/substack/node-commondir/issues" }, "homepage": "https://github.com/substack/node-commondir", "_id": "commondir@1.0.0", "_shasum": "3e1ca7fbeb5d582e007c1df27ca3e1070511db52", "_from": ".", "_npmVersion": "2.3.0", "_nodeVersion": "0.12.0", "_npmUser": { "name": "substack", "email": "mail@substack.net" }, "maintainers": [ { "name": "substack", "email": "mail@substack.net" } ], "dist": { "shasum": "3e1ca7fbeb5d582e007c1df27ca3e1070511db52", "tarball": "https://registry.npmjs.org/commondir/-/commondir-1.0.0.tgz" }, "directories": {} }, "1.0.1": { "name": "commondir", "version": "1.0.1", "description": "compute the closest common parent for file paths", "main": "index.js", "dependencies": {}, "devDependencies": { "tape": "^3.5.0" }, "scripts": { "test": "tape test/*.js" }, "repository": { "type": "git", "url": "http://github.com/substack/node-commondir.git" }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "license": "MIT", "engine": { "node": ">=0.4" }, "gitHead": "57797b60db24c60029f7593995241749b1704902", "bugs": { "url": "https://github.com/substack/node-commondir/issues" }, "homepage": "https://github.com/substack/node-commondir", "_id": "commondir@1.0.1", "_shasum": "ddd800da0c66127393cca5950ea968a3aaf1253b", "_from": ".", "_npmVersion": "2.3.0", "_nodeVersion": "0.12.0", "_npmUser": { "name": "substack", "email": "mail@substack.net" }, "maintainers": [ { "name": "substack", "email": "mail@substack.net" } ], "dist": { "shasum": "ddd800da0c66127393cca5950ea968a3aaf1253b", "tarball": "https://registry.npmjs.org/commondir/-/commondir-1.0.1.tgz" }, "directories": {} } }, "maintainers": [ { "name": "substack", "email": "mail@substack.net" } ], "time": { "modified": "2017-06-02T08:43:35.189Z", "created": "2011-06-28T09:24:34.299Z", "0.0.0": "2011-06-28T09:24:34.962Z", "0.0.1": "2011-11-16T01:05:05.980Z", "0.0.2": "2015-03-14T00:13:42.196Z", "1.0.0": "2015-03-14T00:14:04.458Z", "1.0.1": "2015-03-14T00:15:01.725Z" }, "author": { "name": "James Halliday", "email": "mail@substack.net", "url": "http://substack.net" }, "repository": { "type": "git", "url": "http://github.com/substack/node-commondir.git" }, "users": { "wenbing": true, "simplyianm": true, "erikvold": true, "lassevolkmann": true }, "keywords": [ "common", "path", "directory", "file", "parent", "root" ], "license": "MIT", "readme": "# commondir\n\ncompute the closest common parent directory among an array of directories\n\n# example\n\n``` js\nvar commondir = require('commondir');\nvar dir = commondir(process.argv.slice(2))\nconsole.log(dir);\n```\n\noutput:\n\n```\n$ node dir.js /x/y/z /x/y /x/y/w/q\n/x/y\n$ node ../baz ../../foo/quux ./bizzy\n/foo\n```\n\n# methods\n\n``` js\nvar commondir = require('commondir');\n```\n\n## commondir(absolutePaths)\n\nCompute the closest common parent directory for an array `absolutePaths`.\n\n## commondir(basedir, relativePaths)\n\nCompute the closest common parent directory for an array `relativePaths` which\nwill be resolved for each `dir` in `relativePaths` according to:\n`path.resolve(basedir, dir)`.\n\n# install\n\nWith [npm](https://npmjs.org) do:\n\n```\nnpm install commondir\n```\n\n# license\n\nMIT\n", "readmeFilename": "readme.markdown", "homepage": "https://github.com/substack/node-commondir", "bugs": { "url": "https://github.com/substack/node-commondir/issues" }, "_attachments": {} }