diff options
author | Rebecca Turner <me@re-becca.org> | 2015-08-14 10:24:25 +0300 |
---|---|---|
committer | Rebecca Turner <me@re-becca.org> | 2015-08-14 22:25:45 +0300 |
commit | e429a481dc050420b045f88b89d4db54cb7095be (patch) | |
tree | a2aff25fd6f3b3b61b0d7ad13982355fca93fe9a /node_modules/strip-ansi | |
parent | 797d3ca59e74b26a2466c80ed2d519a070f7a194 (diff) |
columnify@1.5.2
Diffstat (limited to 'node_modules/strip-ansi')
-rwxr-xr-x | node_modules/strip-ansi/cli.js | 47 | ||||
-rw-r--r-- | node_modules/strip-ansi/license | 21 | ||||
-rw-r--r-- | node_modules/strip-ansi/package.json | 50 | ||||
-rw-r--r-- | node_modules/strip-ansi/readme.md | 22 |
4 files changed, 51 insertions, 89 deletions
diff --git a/node_modules/strip-ansi/cli.js b/node_modules/strip-ansi/cli.js deleted file mode 100755 index b83f63b90..000000000 --- a/node_modules/strip-ansi/cli.js +++ /dev/null @@ -1,47 +0,0 @@ -#!/usr/bin/env node -'use strict'; -var fs = require('fs'); -var pkg = require('./package.json'); -var stripAnsi = require('./'); -var argv = process.argv.slice(2); -var input = argv[0]; - -function help() { - console.log([ - '', - ' ' + pkg.description, - '', - ' Usage', - ' strip-ansi <input-file> > <output-file>', - ' cat <input-file> | strip-ansi > <output-file>', - '', - ' Example', - ' strip-ansi unicorn.txt > unicorn-stripped.txt' - ].join('\n')); -} - -function init(data) { - process.stdout.write(stripAnsi(data)); -} - -if (argv.indexOf('--help') !== -1) { - help(); - return; -} - -if (argv.indexOf('--version') !== -1) { - console.log(pkg.version); - return; -} - -if (!input && process.stdin.isTTY) { - help(); - return; -} - -if (input) { - init(fs.readFileSync(input, 'utf8')); -} else { - process.stdin.setEncoding('utf8'); - process.stdin.on('data', init); -} diff --git a/node_modules/strip-ansi/license b/node_modules/strip-ansi/license new file mode 100644 index 000000000..654d0bfe9 --- /dev/null +++ b/node_modules/strip-ansi/license @@ -0,0 +1,21 @@ +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/strip-ansi/package.json b/node_modules/strip-ansi/package.json index d6c76b127..765c6921f 100644 --- a/node_modules/strip-ansi/package.json +++ b/node_modules/strip-ansi/package.json @@ -1,73 +1,69 @@ { "_args": [ [ - "strip-ansi@^2.0.1", - "/Users/rebecca/code/npm/node_modules/columnify" + "strip-ansi@^3.0.0", + "/Users/rebecca/code/npm/node_modules/chalk" ] ], - "_from": "strip-ansi@>=2.0.1 <3.0.0", - "_id": "strip-ansi@2.0.1", + "_from": "strip-ansi@>=3.0.0 <4.0.0", + "_id": "strip-ansi@3.0.0", "_inCache": true, "_location": "/strip-ansi", + "_nodeVersion": "0.12.5", "_npmUser": { "email": "sindresorhus@gmail.com", "name": "sindresorhus" }, - "_npmVersion": "1.4.28", + "_npmVersion": "2.11.2", "_phantomChildren": {}, "_requested": { "name": "strip-ansi", - "raw": "strip-ansi@^2.0.1", - "rawSpec": "^2.0.1", + "raw": "strip-ansi@^3.0.0", + "rawSpec": "^3.0.0", "scope": null, - "spec": ">=2.0.1 <3.0.0", + "spec": ">=3.0.0 <4.0.0", "type": "range" }, "_requiredBy": [ "/chalk", "/columnify" ], - "_resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-2.0.1.tgz", - "_shasum": "df62c1aa94ed2f114e1d0f21fd1d50482b79a60e", + "_resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.0.tgz", + "_shasum": "7510b665567ca914ccb5d7e072763ac968be3724", "_shrinkwrap": null, - "_spec": "strip-ansi@^2.0.1", - "_where": "/Users/rebecca/code/npm/node_modules/columnify", + "_spec": "strip-ansi@^3.0.0", + "_where": "/Users/rebecca/code/npm/node_modules/chalk", "author": { "email": "sindresorhus@gmail.com", "name": "Sindre Sorhus", - "url": "http://sindresorhus.com" - }, - "bin": { - "strip-ansi": "cli.js" + "url": "sindresorhus.com" }, "bugs": { "url": "https://github.com/sindresorhus/strip-ansi/issues" }, "dependencies": { - "ansi-regex": "^1.0.0" + "ansi-regex": "^2.0.0" }, "description": "Strip ANSI escape codes", "devDependencies": { - "mocha": "*" + "ava": "0.0.4" }, "directories": {}, "dist": { - "shasum": "df62c1aa94ed2f114e1d0f21fd1d50482b79a60e", - "tarball": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-2.0.1.tgz" + "shasum": "7510b665567ca914ccb5d7e072763ac968be3724", + "tarball": "http://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.0.tgz" }, "engines": { "node": ">=0.10.0" }, "files": [ - "cli.js", "index.js" ], - "gitHead": "1eff0936c01f89efa312d9d51deed137259871a1", + "gitHead": "3f05b9810e1438f946e2eb84ee854cc00b972e9e", "homepage": "https://github.com/sindresorhus/strip-ansi", "keywords": [ "256", "ansi", - "cli", "color", "colors", "colour", @@ -102,12 +98,14 @@ ], "name": "strip-ansi", "optionalDependencies": {}, + "readme": "# strip-ansi [![Build Status](https://travis-ci.org/sindresorhus/strip-ansi.svg?branch=master)](https://travis-ci.org/sindresorhus/strip-ansi)\n\n> Strip [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code)\n\n\n## Install\n\n```\n$ npm install --save strip-ansi\n```\n\n\n## Usage\n\n```js\nvar stripAnsi = require('strip-ansi');\n\nstripAnsi('\\u001b[4mcake\\u001b[0m');\n//=> 'cake'\n```\n\n\n## Related\n\n- [strip-ansi-cli](https://github.com/sindresorhus/strip-ansi-cli) - CLI for this module\n- [has-ansi](https://github.com/sindresorhus/has-ansi) - Check if a string has ANSI escape codes\n- [ansi-regex](https://github.com/sindresorhus/ansi-regex) - Regular expression for matching ANSI escape codes\n- [chalk](https://github.com/sindresorhus/chalk) - Terminal string styling done right\n\n\n## License\n\nMIT © [Sindre Sorhus](http://sindresorhus.com)\n", + "readmeFilename": "readme.md", "repository": { "type": "git", - "url": "https://github.com/sindresorhus/strip-ansi" + "url": "git+https://github.com/sindresorhus/strip-ansi.git" }, "scripts": { - "test": "mocha" + "test": "node test.js" }, - "version": "2.0.1" + "version": "3.0.0" } diff --git a/node_modules/strip-ansi/readme.md b/node_modules/strip-ansi/readme.md index 53ec26436..76091512d 100644 --- a/node_modules/strip-ansi/readme.md +++ b/node_modules/strip-ansi/readme.md @@ -5,7 +5,7 @@ ## Install -```sh +``` $ npm install --save strip-ansi ``` @@ -20,22 +20,12 @@ stripAnsi('\u001b[4mcake\u001b[0m'); ``` -## CLI - -```sh -$ npm install --global strip-ansi -``` - -```sh -$ strip-ansi --help - - Usage - strip-ansi <input-file> > <output-file> - cat <input-file> | strip-ansi > <output-file> +## Related - Example - strip-ansi unicorn.txt > unicorn-stripped.txt -``` +- [strip-ansi-cli](https://github.com/sindresorhus/strip-ansi-cli) - CLI for this module +- [has-ansi](https://github.com/sindresorhus/has-ansi) - Check if a string has ANSI escape codes +- [ansi-regex](https://github.com/sindresorhus/ansi-regex) - Regular expression for matching ANSI escape codes +- [chalk](https://github.com/sindresorhus/chalk) - Terminal string styling done right ## License |