aboutsummaryrefslogtreecommitdiff
path: root/node_modules/is-path-cwd
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/is-path-cwd')
-rw-r--r--node_modules/is-path-cwd/index.js6
-rw-r--r--node_modules/is-path-cwd/package.json33
-rw-r--r--node_modules/is-path-cwd/readme.md28
3 files changed, 67 insertions, 0 deletions
diff --git a/node_modules/is-path-cwd/index.js b/node_modules/is-path-cwd/index.js
new file mode 100644
index 000000000..24b6fdea3
--- /dev/null
+++ b/node_modules/is-path-cwd/index.js
@@ -0,0 +1,6 @@
+'use strict';
+var path = require('path');
+
+module.exports = function (str) {
+ return path.resolve(str) === path.resolve(process.cwd());
+};
diff --git a/node_modules/is-path-cwd/package.json b/node_modules/is-path-cwd/package.json
new file mode 100644
index 000000000..3aa84f7ea
--- /dev/null
+++ b/node_modules/is-path-cwd/package.json
@@ -0,0 +1,33 @@
+{
+ "name": "is-path-cwd",
+ "version": "1.0.0",
+ "description": "Check if a path is CWD",
+ "license": "MIT",
+ "repository": "sindresorhus/is-path-cwd",
+ "author": {
+ "name": "Sindre Sorhus",
+ "email": "sindresorhus@gmail.com",
+ "url": "http://sindresorhus.com"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "files": [
+ "index.js"
+ ],
+ "keywords": [
+ "path",
+ "cwd",
+ "pwd",
+ "check",
+ "filepath",
+ "file",
+ "folder"
+ ],
+ "devDependencies": {
+ "mocha": "*"
+ }
+}
diff --git a/node_modules/is-path-cwd/readme.md b/node_modules/is-path-cwd/readme.md
new file mode 100644
index 000000000..2d9d65f98
--- /dev/null
+++ b/node_modules/is-path-cwd/readme.md
@@ -0,0 +1,28 @@
+# is-path-cwd [![Build Status](https://travis-ci.org/sindresorhus/is-path-cwd.svg?branch=master)](https://travis-ci.org/sindresorhus/is-path-cwd)
+
+> Check if a path is [CWD](http://en.wikipedia.org/wiki/Working_directory)
+
+
+## Install
+
+```sh
+$ npm install --save is-path-cwd
+```
+
+
+## Usage
+
+```js
+var isPathCwd = require('is-path-cwd');
+
+isPathCwd(process.cwd());
+//=> true
+
+isPathCwd('unicorn');
+//=> false
+```
+
+
+## License
+
+MIT © [Sindre Sorhus](http://sindresorhus.com)