aboutsummaryrefslogtreecommitdiff
path: root/node_modules/glob-parent
diff options
context:
space:
mode:
authorDimitri Staessens <dimitri@ouroboros.rocks>2019-10-06 21:37:45 +0200
committerDimitri Staessens <dimitri@ouroboros.rocks>2019-10-06 21:37:45 +0200
commit3c51c3be85bb0d1bdb87ea0d6632f1c256912f27 (patch)
treec7ccc8279b12c4f7bdbbb4270d617e48f51722e4 /node_modules/glob-parent
parent412c104bebc507bea9c94fd53b5bdc4b64cbfe31 (diff)
downloadwebsite-3c51c3be85bb0d1bdb87ea0d6632f1c256912f27.tar.gz
website-3c51c3be85bb0d1bdb87ea0d6632f1c256912f27.zip
build: Add some required modules for node
Diffstat (limited to 'node_modules/glob-parent')
-rw-r--r--node_modules/glob-parent/LICENSE15
-rw-r--r--node_modules/glob-parent/README.md109
-rw-r--r--node_modules/glob-parent/index.js24
-rw-r--r--node_modules/glob-parent/node_modules/is-glob/LICENSE21
-rw-r--r--node_modules/glob-parent/node_modules/is-glob/README.md142
-rw-r--r--node_modules/glob-parent/node_modules/is-glob/index.js25
-rw-r--r--node_modules/glob-parent/node_modules/is-glob/package.json123
-rw-r--r--node_modules/glob-parent/package.json77
8 files changed, 536 insertions, 0 deletions
diff --git a/node_modules/glob-parent/LICENSE b/node_modules/glob-parent/LICENSE
new file mode 100644
index 0000000..734076d
--- /dev/null
+++ b/node_modules/glob-parent/LICENSE
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) 2015 Elan Shanker
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
diff --git a/node_modules/glob-parent/README.md b/node_modules/glob-parent/README.md
new file mode 100644
index 0000000..3bec5c7
--- /dev/null
+++ b/node_modules/glob-parent/README.md
@@ -0,0 +1,109 @@
+glob-parent [![Build Status](https://travis-ci.org/es128/glob-parent.svg)](https://travis-ci.org/es128/glob-parent) [![Coverage Status](https://img.shields.io/coveralls/es128/glob-parent.svg)](https://coveralls.io/r/es128/glob-parent?branch=master)
+======
+Javascript module to extract the non-magic parent path from a glob string.
+
+[![NPM](https://nodei.co/npm/glob-parent.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/glob-parent/)
+[![NPM](https://nodei.co/npm-dl/glob-parent.png?height=3&months=9)](https://nodei.co/npm-dl/glob-parent/)
+
+Usage
+-----
+```sh
+npm install glob-parent --save
+```
+
+**Examples**
+
+```js
+var globParent = require('glob-parent');
+
+globParent('path/to/*.js'); // 'path/to'
+globParent('/root/path/to/*.js'); // '/root/path/to'
+globParent('/*.js'); // '/'
+globParent('*.js'); // '.'
+globParent('**/*.js'); // '.'
+globParent('path/{to,from}'); // 'path'
+globParent('path/!(to|from)'); // 'path'
+globParent('path/?(to|from)'); // 'path'
+globParent('path/+(to|from)'); // 'path'
+globParent('path/*(to|from)'); // 'path'
+globParent('path/@(to|from)'); // 'path'
+globParent('path/**/*'); // 'path'
+
+// if provided a non-glob path, returns the nearest dir
+globParent('path/foo/bar.js'); // 'path/foo'
+globParent('path/foo/'); // 'path/foo'
+globParent('path/foo'); // 'path' (see issue #3 for details)
+```
+
+## Escaping
+
+The following characters have special significance in glob patterns and must be escaped if you want them to be treated as regular path characters:
+
+- `?` (question mark)
+- `*` (star)
+- `|` (pipe)
+- `(` (opening parenthesis)
+- `)` (closing parenthesis)
+- `{` (opening curly brace)
+- `}` (closing curly brace)
+- `[` (opening bracket)
+- `]` (closing bracket)
+
+**Example**
+
+```js
+globParent('foo/[bar]/') // 'foo'
+globParent('foo/\\[bar]/') // 'foo/[bar]'
+```
+
+## Limitations
+
+#### Braces & Brackets
+This library attempts a quick and imperfect method of determining which path
+parts have glob magic without fully parsing/lexing the pattern. There are some
+advanced use cases that can trip it up, such as nested braces where the outer
+pair is escaped and the inner one contains a path separator. If you find
+yourself in the unlikely circumstance of being affected by this or need to
+ensure higher-fidelity glob handling in your library, it is recommended that you
+pre-process your input with [expand-braces] and/or [expand-brackets].
+
+#### Windows
+Backslashes are not valid path separators for globs. If a path with backslashes
+is provided anyway, for simple cases, glob-parent will replace the path
+separator for you and return the non-glob parent path (now with
+forward-slashes, which are still valid as Windows path separators).
+
+This cannot be used in conjunction with escape characters.
+
+```js
+// BAD
+globParent('C:\\Program Files \\(x86\\)\\*.ext') // 'C:/Program Files /(x86/)'
+
+// GOOD
+globParent('C:/Program Files\\(x86\\)/*.ext') // 'C:/Program Files (x86)'
+```
+
+If you are using escape characters for a pattern without path parts (i.e.
+relative to `cwd`), prefix with `./` to avoid confusing glob-parent.
+
+```js
+// BAD
+globParent('foo \\[bar]') // 'foo '
+globParent('foo \\[bar]*') // 'foo '
+
+// GOOD
+globParent('./foo \\[bar]') // 'foo [bar]'
+globParent('./foo \\[bar]*') // '.'
+```
+
+
+Change Log
+----------
+[See release notes page on GitHub](https://github.com/es128/glob-parent/releases)
+
+License
+-------
+[ISC](https://raw.github.com/es128/glob-parent/master/LICENSE)
+
+[expand-braces]: https://github.com/jonschlinkert/expand-braces
+[expand-brackets]: https://github.com/jonschlinkert/expand-brackets
diff --git a/node_modules/glob-parent/index.js b/node_modules/glob-parent/index.js
new file mode 100644
index 0000000..3a14a53
--- /dev/null
+++ b/node_modules/glob-parent/index.js
@@ -0,0 +1,24 @@
+'use strict';
+
+var path = require('path');
+var isglob = require('is-glob');
+var pathDirname = require('path-dirname');
+var isWin32 = require('os').platform() === 'win32';
+
+module.exports = function globParent(str) {
+ // flip windows path separators
+ if (isWin32 && str.indexOf('/') < 0) str = str.split('\\').join('/');
+
+ // special case for strings ending in enclosure containing path separator
+ if (/[\{\[].*[\/]*.*[\}\]]$/.test(str)) str += '/';
+
+ // preserves full path in case of trailing path separator
+ str += 'a';
+
+ // remove path parts that are globby
+ do {str = pathDirname.posix(str)}
+ while (isglob(str) || /(^|[^\\])([\{\[]|\([^\)]+$)/.test(str));
+
+ // remove escape chars and return result
+ return str.replace(/\\([\*\?\|\[\]\(\)\{\}])/g, '$1');
+};
diff --git a/node_modules/glob-parent/node_modules/is-glob/LICENSE b/node_modules/glob-parent/node_modules/is-glob/LICENSE
new file mode 100644
index 0000000..39245ac
--- /dev/null
+++ b/node_modules/glob-parent/node_modules/is-glob/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2016, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/glob-parent/node_modules/is-glob/README.md b/node_modules/glob-parent/node_modules/is-glob/README.md
new file mode 100644
index 0000000..6f4404f
--- /dev/null
+++ b/node_modules/glob-parent/node_modules/is-glob/README.md
@@ -0,0 +1,142 @@
+# is-glob [![NPM version](https://img.shields.io/npm/v/is-glob.svg?style=flat)](https://www.npmjs.com/package/is-glob) [![NPM downloads](https://img.shields.io/npm/dm/is-glob.svg?style=flat)](https://npmjs.org/package/is-glob) [![Build Status](https://img.shields.io/travis/jonschlinkert/is-glob.svg?style=flat)](https://travis-ci.org/jonschlinkert/is-glob)
+
+> Returns `true` if the given string looks like a glob pattern or an extglob pattern. This makes it easy to create code that only uses external modules like node-glob when necessary, resulting in much faster code execution and initialization time, and a better user experience.
+
+## Install
+
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install --save is-glob
+```
+
+You might also be interested in [is-valid-glob](https://github.com/jonschlinkert/is-valid-glob) and [has-glob](https://github.com/jonschlinkert/has-glob).
+
+## Usage
+
+```js
+var isGlob = require('is-glob');
+```
+
+**True**
+
+Patterns that have glob characters or regex patterns will return `true`:
+
+```js
+isGlob('!foo.js');
+isGlob('*.js');
+isGlob('**/abc.js');
+isGlob('abc/*.js');
+isGlob('abc/(aaa|bbb).js');
+isGlob('abc/[a-z].js');
+isGlob('abc/{a,b}.js');
+isGlob('abc/?.js');
+//=> true
+```
+
+Extglobs
+
+```js
+isGlob('abc/@(a).js');
+isGlob('abc/!(a).js');
+isGlob('abc/+(a).js');
+isGlob('abc/*(a).js');
+isGlob('abc/?(a).js');
+//=> true
+```
+
+**False**
+
+Escaped globs or extglobs return `false`:
+
+```js
+isGlob('abc/\\@(a).js');
+isGlob('abc/\\!(a).js');
+isGlob('abc/\\+(a).js');
+isGlob('abc/\\*(a).js');
+isGlob('abc/\\?(a).js');
+isGlob('\\!foo.js');
+isGlob('\\*.js');
+isGlob('\\*\\*/abc.js');
+isGlob('abc/\\*.js');
+isGlob('abc/\\(aaa|bbb).js');
+isGlob('abc/\\[a-z].js');
+isGlob('abc/\\{a,b}.js');
+isGlob('abc/\\?.js');
+//=> false
+```
+
+Patterns that do not have glob patterns return `false`:
+
+```js
+isGlob('abc.js');
+isGlob('abc/def/ghi.js');
+isGlob('foo.js');
+isGlob('abc/@.js');
+isGlob('abc/+.js');
+isGlob();
+isGlob(null);
+//=> false
+```
+
+Arrays are also `false` (If you want to check if an array has a glob pattern, use [has-glob](https://github.com/jonschlinkert/has-glob)):
+
+```js
+isGlob(['**/*.js']);
+isGlob(['foo.js']);
+//=> false
+```
+
+## About
+
+### Related projects
+
+* [assemble](https://www.npmjs.com/package/assemble): Get the rocks out of your socks! Assemble makes you fast at creating web projects… [more](https://github.com/assemble/assemble) | [homepage](https://github.com/assemble/assemble "Get the rocks out of your socks! Assemble makes you fast at creating web projects. Assemble is used by thousands of projects for rapid prototyping, creating themes, scaffolds, boilerplates, e-books, UI components, API documentation, blogs, building websit")
+* [base](https://www.npmjs.com/package/base): base is the foundation for creating modular, unit testable and highly pluggable node.js applications, starting… [more](https://github.com/node-base/base) | [homepage](https://github.com/node-base/base "base is the foundation for creating modular, unit testable and highly pluggable node.js applications, starting with a handful of common methods, like `set`, `get`, `del` and `use`.")
+* [update](https://www.npmjs.com/package/update): Be scalable! Update is a new, open source developer framework and CLI for automating updates… [more](https://github.com/update/update) | [homepage](https://github.com/update/update "Be scalable! Update is a new, open source developer framework and CLI for automating updates of any kind in code projects.")
+* [verb](https://www.npmjs.com/package/verb): Documentation generator for GitHub projects. Verb is extremely powerful, easy to use, and is used… [more](https://github.com/verbose/verb) | [homepage](https://github.com/verbose/verb "Documentation generator for GitHub projects. Verb is extremely powerful, easy to use, and is used on hundreds of projects of all sizes to generate everything from API docs to readmes.")
+
+### Contributing
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
+
+### Contributors
+
+| **Commits** | **Contributor**<br/> |
+| --- | --- |
+| 40 | [jonschlinkert](https://github.com/jonschlinkert) |
+| 1 | [tuvistavie](https://github.com/tuvistavie) |
+
+### Building docs
+
+_(This document was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme) (a [verb](https://github.com/verbose/verb) generator), please don't edit the readme directly. Any changes to the readme must be made in [.verb.md](.verb.md).)_
+
+To generate the readme and API documentation with [verb](https://github.com/verbose/verb):
+
+```sh
+$ npm install -g verb verb-generate-readme && verb
+```
+
+### Running tests
+
+Install dev dependencies:
+
+```sh
+$ npm install -d && npm test
+```
+
+### Author
+
+**Jon Schlinkert**
+
+* [github/jonschlinkert](https://github.com/jonschlinkert)
+* [twitter/jonschlinkert](http://twitter.com/jonschlinkert)
+
+### License
+
+Copyright © 2016, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT license](https://github.com/jonschlinkert/is-glob/blob/master/LICENSE).
+
+***
+
+_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.1.31, on October 12, 2016._ \ No newline at end of file
diff --git a/node_modules/glob-parent/node_modules/is-glob/index.js b/node_modules/glob-parent/node_modules/is-glob/index.js
new file mode 100644
index 0000000..2ecbe2a
--- /dev/null
+++ b/node_modules/glob-parent/node_modules/is-glob/index.js
@@ -0,0 +1,25 @@
+/*!
+ * is-glob <https://github.com/jonschlinkert/is-glob>
+ *
+ * Copyright (c) 2014-2016, Jon Schlinkert.
+ * Licensed under the MIT License.
+ */
+
+var isExtglob = require('is-extglob');
+
+module.exports = function isGlob(str) {
+ if (typeof str !== 'string' || str === '') {
+ return false;
+ }
+
+ if (isExtglob(str)) return true;
+
+ var regex = /(\\).|([*?]|\[.*\]|\{.*\}|\(.*\|.*\)|^!)/;
+ var match;
+
+ while ((match = regex.exec(str))) {
+ if (match[2]) return true;
+ str = str.slice(match.index + match[0].length);
+ }
+ return false;
+};
diff --git a/node_modules/glob-parent/node_modules/is-glob/package.json b/node_modules/glob-parent/node_modules/is-glob/package.json
new file mode 100644
index 0000000..79b04c5
--- /dev/null
+++ b/node_modules/glob-parent/node_modules/is-glob/package.json
@@ -0,0 +1,123 @@
+{
+ "_args": [
+ [
+ "is-glob@3.1.0",
+ "/home/dstaesse/git/website"
+ ]
+ ],
+ "_development": true,
+ "_from": "is-glob@3.1.0",
+ "_id": "is-glob@3.1.0",
+ "_inBundle": false,
+ "_integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=",
+ "_location": "/glob-parent/is-glob",
+ "_phantomChildren": {},
+ "_requested": {
+ "type": "version",
+ "registry": true,
+ "raw": "is-glob@3.1.0",
+ "name": "is-glob",
+ "escapedName": "is-glob",
+ "rawSpec": "3.1.0",
+ "saveSpec": null,
+ "fetchSpec": "3.1.0"
+ },
+ "_requiredBy": [
+ "/glob-parent"
+ ],
+ "_resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz",
+ "_spec": "3.1.0",
+ "_where": "/home/dstaesse/git/website",
+ "author": {
+ "name": "Jon Schlinkert",
+ "url": "https://github.com/jonschlinkert"
+ },
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/is-glob/issues"
+ },
+ "contributors": [
+ {
+ "name": "Daniel Perez",
+ "email": "daniel@claudetech.com",
+ "url": "http://tuvistavie.com"
+ },
+ {
+ "name": "Jon Schlinkert",
+ "email": "jon.schlinkert@sellside.com",
+ "url": "http://twitter.com/jonschlinkert"
+ }
+ ],
+ "dependencies": {
+ "is-extglob": "^2.1.0"
+ },
+ "description": "Returns `true` if the given string looks like a glob pattern or an extglob pattern. This makes it easy to create code that only uses external modules like node-glob when necessary, resulting in much faster code execution and initialization time, and a better user experience.",
+ "devDependencies": {
+ "gulp-format-md": "^0.1.10",
+ "mocha": "^3.0.2"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "homepage": "https://github.com/jonschlinkert/is-glob",
+ "keywords": [
+ "bash",
+ "braces",
+ "check",
+ "exec",
+ "expression",
+ "extglob",
+ "glob",
+ "globbing",
+ "globstar",
+ "is",
+ "match",
+ "matches",
+ "pattern",
+ "regex",
+ "regular",
+ "string",
+ "test"
+ ],
+ "license": "MIT",
+ "main": "index.js",
+ "name": "is-glob",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/jonschlinkert/is-glob.git"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "verb": {
+ "layout": "default",
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "related": {
+ "list": [
+ "assemble",
+ "base",
+ "update",
+ "verb"
+ ]
+ },
+ "reflinks": [
+ "assemble",
+ "bach",
+ "base",
+ "composer",
+ "gulp",
+ "has-glob",
+ "is-valid-glob",
+ "micromatch",
+ "npm",
+ "scaffold",
+ "verb",
+ "vinyl"
+ ]
+ },
+ "version": "3.1.0"
+}
diff --git a/node_modules/glob-parent/package.json b/node_modules/glob-parent/package.json
new file mode 100644
index 0000000..ef0757d
--- /dev/null
+++ b/node_modules/glob-parent/package.json
@@ -0,0 +1,77 @@
+{
+ "_args": [
+ [
+ "glob-parent@3.1.0",
+ "/home/dstaesse/git/website"
+ ]
+ ],
+ "_development": true,
+ "_from": "glob-parent@3.1.0",
+ "_id": "glob-parent@3.1.0",
+ "_inBundle": false,
+ "_integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=",
+ "_location": "/glob-parent",
+ "_phantomChildren": {
+ "is-extglob": "2.1.1"
+ },
+ "_requested": {
+ "type": "version",
+ "registry": true,
+ "raw": "glob-parent@3.1.0",
+ "name": "glob-parent",
+ "escapedName": "glob-parent",
+ "rawSpec": "3.1.0",
+ "saveSpec": null,
+ "fetchSpec": "3.1.0"
+ },
+ "_requiredBy": [
+ "/chokidar",
+ "/fast-glob"
+ ],
+ "_resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz",
+ "_spec": "3.1.0",
+ "_where": "/home/dstaesse/git/website",
+ "author": {
+ "name": "Elan Shanker",
+ "url": "https://github.com/es128"
+ },
+ "bugs": {
+ "url": "https://github.com/es128/glob-parent/issues"
+ },
+ "dependencies": {
+ "is-glob": "^3.1.0",
+ "path-dirname": "^1.0.0"
+ },
+ "description": "Strips glob magic from a string to provide the parent directory path",
+ "devDependencies": {
+ "coveralls": "^2.11.2",
+ "istanbul": "^0.3.5",
+ "mocha": "^2.1.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "homepage": "https://github.com/es128/glob-parent",
+ "keywords": [
+ "glob",
+ "parent",
+ "strip",
+ "path",
+ "dirname",
+ "directory",
+ "base",
+ "wildcard"
+ ],
+ "license": "ISC",
+ "main": "index.js",
+ "name": "glob-parent",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/es128/glob-parent.git"
+ },
+ "scripts": {
+ "ci-test": "istanbul cover _mocha && cat ./coverage/lcov.info | coveralls",
+ "test": "istanbul test node_modules/mocha/bin/_mocha"
+ },
+ "version": "3.1.0"
+}