aboutsummaryrefslogtreecommitdiff
path: root/node_modules/globby
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/globby')
-rw-r--r--node_modules/globby/index.js88
-rw-r--r--node_modules/globby/license21
-rw-r--r--node_modules/globby/package.json69
-rw-r--r--node_modules/globby/readme.md88
4 files changed, 0 insertions, 266 deletions
diff --git a/node_modules/globby/index.js b/node_modules/globby/index.js
deleted file mode 100644
index 587a0fdd1..000000000
--- a/node_modules/globby/index.js
+++ /dev/null
@@ -1,88 +0,0 @@
-'use strict';
-var Promise = require('pinkie-promise');
-var arrayUnion = require('array-union');
-var objectAssign = require('object-assign');
-var glob = require('glob');
-var pify = require('pify');
-
-var globP = pify(glob, Promise).bind(glob);
-
-function isNegative(pattern) {
- return pattern[0] === '!';
-}
-
-function isString(value) {
- return typeof value === 'string';
-}
-
-function assertPatternsInput(patterns) {
- if (!patterns.every(isString)) {
- throw new TypeError('patterns must be a string or an array of strings');
- }
-}
-
-function generateGlobTasks(patterns, opts) {
- patterns = [].concat(patterns);
- assertPatternsInput(patterns);
-
- var globTasks = [];
-
- opts = objectAssign({
- cache: Object.create(null),
- statCache: Object.create(null),
- realpathCache: Object.create(null),
- symlinks: Object.create(null),
- ignore: []
- }, opts);
-
- patterns.forEach(function (pattern, i) {
- if (isNegative(pattern)) {
- return;
- }
-
- var ignore = patterns.slice(i).filter(isNegative).map(function (pattern) {
- return pattern.slice(1);
- });
-
- globTasks.push({
- pattern: pattern,
- opts: objectAssign({}, opts, {
- ignore: opts.ignore.concat(ignore)
- })
- });
- });
-
- return globTasks;
-}
-
-module.exports = function (patterns, opts) {
- var globTasks;
-
- try {
- globTasks = generateGlobTasks(patterns, opts);
- } catch (err) {
- return Promise.reject(err);
- }
-
- return Promise.all(globTasks.map(function (task) {
- return globP(task.pattern, task.opts);
- })).then(function (paths) {
- return arrayUnion.apply(null, paths);
- });
-};
-
-module.exports.sync = function (patterns, opts) {
- var globTasks = generateGlobTasks(patterns, opts);
-
- return globTasks.reduce(function (matches, task) {
- return arrayUnion(matches, glob.sync(task.pattern, task.opts));
- }, []);
-};
-
-module.exports.generateGlobTasks = generateGlobTasks;
-
-module.exports.hasMagic = function (patterns, opts) {
- return [].concat(patterns).some(function (pattern) {
- return glob.hasMagic(pattern, opts);
- });
-};
diff --git a/node_modules/globby/license b/node_modules/globby/license
deleted file mode 100644
index 654d0bfe9..000000000
--- a/node_modules/globby/license
+++ /dev/null
@@ -1,21 +0,0 @@
-The MIT License (MIT)
-
-Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
-
-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/globby/package.json b/node_modules/globby/package.json
deleted file mode 100644
index 925148862..000000000
--- a/node_modules/globby/package.json
+++ /dev/null
@@ -1,69 +0,0 @@
-{
- "name": "globby",
- "version": "6.1.0",
- "description": "Extends `glob` with support for multiple patterns and exposes a Promise API",
- "license": "MIT",
- "repository": "sindresorhus/globby",
- "author": {
- "email": "sindresorhus@gmail.com",
- "name": "Sindre Sorhus",
- "url": "sindresorhus.com"
- },
- "engines": {
- "node": ">=0.10.0"
- },
- "scripts": {
- "bench": "npm update glob-stream && matcha bench.js",
- "test": "xo && ava"
- },
- "files": [
- "index.js"
- ],
- "keywords": [
- "all",
- "array",
- "directories",
- "dirs",
- "expand",
- "files",
- "filesystem",
- "filter",
- "find",
- "fnmatch",
- "folders",
- "fs",
- "glob",
- "globbing",
- "globs",
- "gulpfriendly",
- "match",
- "matcher",
- "minimatch",
- "multi",
- "multiple",
- "paths",
- "pattern",
- "patterns",
- "traverse",
- "util",
- "utility",
- "wildcard",
- "wildcards",
- "promise"
- ],
- "dependencies": {
- "array-union": "^1.0.1",
- "glob": "^7.0.3",
- "object-assign": "^4.0.1",
- "pify": "^2.0.0",
- "pinkie-promise": "^2.0.0"
- },
- "devDependencies": {
- "ava": "*",
- "glob-stream": "gulpjs/glob-stream#master",
- "globby": "sindresorhus/globby#master",
- "matcha": "^0.7.0",
- "rimraf": "^2.2.8",
- "xo": "^0.16.0"
- }
-}
diff --git a/node_modules/globby/readme.md b/node_modules/globby/readme.md
deleted file mode 100644
index e10a48868..000000000
--- a/node_modules/globby/readme.md
+++ /dev/null
@@ -1,88 +0,0 @@
-# globby [![Build Status](https://travis-ci.org/sindresorhus/globby.svg?branch=master)](https://travis-ci.org/sindresorhus/globby)
-
-> Extends [glob](https://github.com/isaacs/node-glob) with support for multiple patterns and exposes a Promise API
-
-
-## Install
-
-```
-$ npm install --save globby
-```
-
-
-## Usage
-
-```
-├── unicorn
-├── cake
-└── rainbow
-```
-
-```js
-const globby = require('globby');
-
-globby(['*', '!cake']).then(paths => {
- console.log(paths);
- //=> ['unicorn', 'rainbow']
-});
-```
-
-
-## API
-
-### globby(patterns, [options])
-
-Returns a Promise for an array of matching paths.
-
-### globby.sync(patterns, [options])
-
-Returns an array of matching paths.
-
-### globby.generateGlobTasks(patterns, [options])
-
-Returns an array of objects in the format `{ pattern: string, opts: Object }`, which can be passed as arguments to [`node-glob`](https://github.com/isaacs/node-glob). This is useful for other globbing-related packages.
-
-Note that you should avoid running the same tasks multiple times as they contain a file system cache. Instead, run this method each time to ensure file system changes are taken into consideration.
-
-### globby.hasMagic(patterns, [options])
-
-Returns a `boolean` of whether there are any special glob characters in the `patterns`.
-
-Note that the options affect the results. If `noext: true` is set, then `+(a|b)` will not be considered a magic pattern. If the pattern has a brace expansion, like `a/{b/c,x/y}`, then that is considered magical, unless `nobrace: true` is set.
-
-#### patterns
-
-Type: `string` `Array`
-
-See supported `minimatch` [patterns](https://github.com/isaacs/minimatch#usage).
-
-#### options
-
-Type: `Object`
-
-See the `node-glob` [options](https://github.com/isaacs/node-glob#options).
-
-
-## Globbing patterns
-
-Just a quick overview.
-
-- `*` matches any number of characters, but not `/`
-- `?` matches a single character, but not `/`
-- `**` matches any number of characters, including `/`, as long as it's the only thing in a path part
-- `{}` allows for a comma-separated list of "or" expressions
-- `!` at the beginning of a pattern will negate the match
-
-[Various patterns and expected matches.](https://github.com/sindresorhus/multimatch/blob/master/test.js)
-
-
-## Related
-
-- [multimatch](https://github.com/sindresorhus/multimatch) - Match against a list instead of the filesystem
-- [glob-stream](https://github.com/wearefractal/glob-stream) - Streaming alternative
-- [matcher](https://github.com/sindresorhus/matcher) - Simple wildcard matching
-
-
-## License
-
-MIT © [Sindre Sorhus](https://sindresorhus.com)