Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRebecca Turner <me@re-becca.org>2017-06-27 01:11:59 +0300
committerRebecca Turner <me@re-becca.org>2017-06-27 01:23:27 +0300
commita5275fb21b69de3af4be7768d53d0ff2d2ff66d3 (patch)
treecde50cc08c2e89b65a470266dc4f16ff83e60622 /node_modules/ansi-regex
parentd2b47442ae1e48d9e60d154129e4bec8b3ef27c7 (diff)
ansi-regex@3.0.0
Diffstat (limited to 'node_modules/ansi-regex')
-rw-r--r--node_modules/ansi-regex/index.js10
-rw-r--r--node_modules/ansi-regex/license20
-rw-r--r--node_modules/ansi-regex/package.json70
-rw-r--r--node_modules/ansi-regex/readme.md21
4 files changed, 45 insertions, 76 deletions
diff --git a/node_modules/ansi-regex/index.js b/node_modules/ansi-regex/index.js
index b9574ed7e..c4aaecf50 100644
--- a/node_modules/ansi-regex/index.js
+++ b/node_modules/ansi-regex/index.js
@@ -1,4 +1,10 @@
'use strict';
-module.exports = function () {
- return /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-PRZcf-nqry=><]/g;
+
+module.exports = () => {
+ const pattern = [
+ '[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:[a-zA-Z\\d]*(?:;[a-zA-Z\\d]*)*)?\\u0007)',
+ '(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PRZcf-ntqry=><~]))'
+ ].join('|');
+
+ return new RegExp(pattern, 'g');
};
diff --git a/node_modules/ansi-regex/license b/node_modules/ansi-regex/license
index 654d0bfe9..e7af2f771 100644
--- a/node_modules/ansi-regex/license
+++ b/node_modules/ansi-regex/license
@@ -1,21 +1,9 @@
-The MIT License (MIT)
+MIT License
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:
+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 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.
+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/ansi-regex/package.json b/node_modules/ansi-regex/package.json
index bf854fdc3..2bf2bb485 100644
--- a/node_modules/ansi-regex/package.json
+++ b/node_modules/ansi-regex/package.json
@@ -1,52 +1,45 @@
{
- "_from": "ansi-regex@~2.1.1",
- "_id": "ansi-regex@2.1.1",
- "_integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=",
+ "_from": "ansi-regex@latest",
+ "_id": "ansi-regex@3.0.0",
+ "_inBundle": false,
+ "_integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=",
"_location": "/ansi-regex",
"_phantomChildren": {},
"_requested": {
- "type": "range",
+ "type": "tag",
"registry": true,
- "raw": "ansi-regex@~2.1.1",
+ "raw": "ansi-regex@latest",
"name": "ansi-regex",
"escapedName": "ansi-regex",
- "rawSpec": "~2.1.1",
+ "rawSpec": "latest",
"saveSpec": null,
- "fetchSpec": "~2.1.1"
+ "fetchSpec": "latest"
},
"_requiredBy": [
- "/",
- "/npm-registry-couchapp/couchapp/nano/follow/request/har-validator/chalk/has-ansi",
- "/standard/eslint/chalk/has-ansi",
- "/standard/eslint/inquirer",
- "/strip-ansi",
- "/tap/coveralls/request/har-validator/chalk/has-ansi",
- "/update-notifier/chalk/has-ansi"
+ "#USER",
+ "/"
],
- "_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
- "_shasum": "c3b33ab5ee360d86e0e628f0468ae7ef27d654df",
- "_shrinkwrap": null,
- "_spec": "ansi-regex@~2.1.1",
- "_where": "/Users/zkat/Documents/code/npm",
+ "_resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz",
+ "_shasum": "ed0317c322064f79466c02966bddb605ab37d998",
+ "_spec": "ansi-regex@latest",
+ "_where": "/Users/rebecca/code/npm",
"author": {
"name": "Sindre Sorhus",
"email": "sindresorhus@gmail.com",
"url": "sindresorhus.com"
},
- "bin": null,
"bugs": {
"url": "https://github.com/chalk/ansi-regex/issues"
},
"bundleDependencies": false,
- "dependencies": {},
"deprecated": false,
"description": "Regular expression for matching ANSI escape codes",
"devDependencies": {
- "ava": "0.17.0",
- "xo": "0.16.0"
+ "ava": "*",
+ "xo": "*"
},
"engines": {
- "node": ">=0.10.0"
+ "node": ">=4"
},
"files": [
"index.js"
@@ -80,39 +73,14 @@
"pattern"
],
"license": "MIT",
- "maintainers": [
- {
- "name": "Sindre Sorhus",
- "email": "sindresorhus@gmail.com",
- "url": "sindresorhus.com"
- },
- {
- "name": "Joshua Appelman",
- "email": "jappelman@xebia.com",
- "url": "jbnicolai.com"
- },
- {
- "name": "JD Ballard",
- "email": "i.am.qix@gmail.com",
- "url": "github.com/qix-"
- }
- ],
"name": "ansi-regex",
- "optionalDependencies": {},
- "peerDependencies": {},
"repository": {
"type": "git",
"url": "git+https://github.com/chalk/ansi-regex.git"
},
"scripts": {
- "test": "xo && ava --verbose",
+ "test": "xo && ava",
"view-supported": "node fixtures/view-codes.js"
},
- "version": "2.1.1",
- "xo": {
- "rules": {
- "guard-for-in": 0,
- "no-loop-func": 0
- }
- }
+ "version": "3.0.0"
}
diff --git a/node_modules/ansi-regex/readme.md b/node_modules/ansi-regex/readme.md
index 6a928edf0..22db1c340 100644
--- a/node_modules/ansi-regex/readme.md
+++ b/node_modules/ansi-regex/readme.md
@@ -1,12 +1,12 @@
# ansi-regex [![Build Status](https://travis-ci.org/chalk/ansi-regex.svg?branch=master)](https://travis-ci.org/chalk/ansi-regex)
-> Regular expression for matching [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code)
+> Regular expression for matching [ANSI escape codes](https://en.wikipedia.org/wiki/ANSI_escape_code)
## Install
```
-$ npm install --save ansi-regex
+$ npm install ansi-regex
```
@@ -15,25 +15,32 @@ $ npm install --save ansi-regex
```js
const ansiRegex = require('ansi-regex');
-ansiRegex().test('\u001b[4mcake\u001b[0m');
+ansiRegex().test('\u001B[4mcake\u001B[0m');
//=> true
ansiRegex().test('cake');
//=> false
-'\u001b[4mcake\u001b[0m'.match(ansiRegex());
-//=> ['\u001b[4m', '\u001b[0m']
+'\u001B[4mcake\u001B[0m'.match(ansiRegex());
+//=> ['\u001B[4m', '\u001B[0m']
```
+
## FAQ
### Why do you test for codes not in the ECMA 48 standard?
-Some of the codes we run as a test are codes that we acquired finding various lists of non-standard or manufacturer specific codes. If I recall correctly, we test for both standard and non-standard codes, as most of them follow the same or similar format and can be safely matched in strings without the risk of removing actual string content. There are a few non-standard control codes that do not follow the traditional format (i.e. they end in numbers) thus forcing us to exclude them from the test because we cannot reliably match them.
+Some of the codes we run as a test are codes that we acquired finding various lists of non-standard or manufacturer specific codes. We test for both standard and non-standard codes, as most of them follow the same or similar format and can be safely matched in strings without the risk of removing actual string content. There are a few non-standard control codes that do not follow the traditional format (i.e. they end in numbers) thus forcing us to exclude them from the test because we cannot reliably match them.
On the historical side, those ECMA standards were established in the early 90's whereas the VT100, for example, was designed in the mid/late 70's. At that point in time, control codes were still pretty ungoverned and engineers used them for a multitude of things, namely to activate hardware ports that may have been proprietary. Somewhere else you see a similar 'anarchy' of codes is in the x86 architecture for processors; there are a ton of "interrupts" that can mean different things on certain brands of processors, most of which have been phased out.
+## Maintainers
+
+- [Sindre Sorhus](https://github.com/sindresorhus)
+- [Josh Junon](https://github.com/qix-)
+
+
## License
-MIT © [Sindre Sorhus](http://sindresorhus.com)
+MIT