diff --git a/Gruntfile.coffee b/Gruntfile.coffee index c377b03..a2f86cc 100644 --- a/Gruntfile.coffee +++ b/Gruntfile.coffee @@ -5,6 +5,7 @@ module.exports = (grunt) -> grunt.loadNpmTasks 'grunt-contrib-watch' grunt.loadNpmTasks 'grunt-contrib-connect' grunt.loadNpmTasks 'grunt-contrib-coffee' + grunt.loadNpmTasks 'grunt-contrib-uglify' # project configuration grunt.initConfig @@ -33,6 +34,10 @@ module.exports = (grunt) -> server: options: port: 8000 - - grunt.registerTask('default', ['connect', 'watch']) + uglify: + my_target: + files: 'scripts/player.min.js':'scripts/player.js' + + grunt.registerTask('server', ['connect', 'watch']) + grunt.registerTask('deploy', ['uglify', 'sass', 'coffee','production']) diff --git a/README.md b/README.md index c71c870..4ec284c 100644 --- a/README.md +++ b/README.md @@ -1,21 +1,30 @@ # .wiredIn() -Somos loucos por música. Somos loucos por desenvolvimento. O __.wiredIn()__ é +![Logo WiredIn](images/readme_header.jpg) + +Somos loucos por música. Somos loucos por desenvolvimento. O [__.wiredIn()__](http://wiredin.loopinfinito.com.br) é uma coletânea periódica de músicas pra te ajudar a se manter focado e mais produtivo. Aperte o play e deixe seus commits fluírem. ## Como contribuir -O projeto é todo feito apenas com puro HTML, CSS e JS. -Basta por o projeto em seu `htdocs` ou, então, digite em seu terminal: +1- Faça o clone do projeto para o seu computador. + +2- O projeto é todo feito apenas com puro HTML, CSS e JS. +Como utilizamos o [Grunt.JS](http://www.gruntjs.com), basta digitar: + +`grunt server` + +Ele ira gerar um servidor em `localhost:8000`. +Como utilizamos também [Sass](http://www.sass-lang.com), ele fica observando e compila automaticamente qualquer alteração. + +3- Antes de submeter suas modificações, digite o comando: + +`grunt deploy` -```bash -$ cd wired-in -$ python -m SimpleHTTPServer -``` +Assim o projeto estará pronto. -E aponte o seu navegador para `localhost:8000`. Simples assim. -Faça suas alterações e nos envie um _pull request_. +4- Agora é só nós enviar um _pull request_. ## Licença diff --git a/node_modules/grunt-contrib-uglify/LICENSE-MIT b/node_modules/grunt-contrib-uglify/LICENSE-MIT new file mode 100644 index 0000000..8368849 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/LICENSE-MIT @@ -0,0 +1,22 @@ +Copyright (c) 2013 "Cowboy" Ben Alman, contributors + +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/grunt-contrib-uglify/README.md b/node_modules/grunt-contrib-uglify/README.md new file mode 100644 index 0000000..2fbbd02 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/README.md @@ -0,0 +1,381 @@ +# grunt-contrib-uglify v0.3.1 [![Build Status](https://travis-ci.org/gruntjs/grunt-contrib-uglify.png?branch=master)](https://travis-ci.org/gruntjs/grunt-contrib-uglify) + +> Minify files with UglifyJS. + + + +## Getting Started +This plugin requires Grunt `~0.4.0` + +If you haven't used [Grunt](http://gruntjs.com/) before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a [Gruntfile](http://gruntjs.com/sample-gruntfile) as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command: + +```shell +npm install grunt-contrib-uglify --save-dev +``` + +Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript: + +```js +grunt.loadNpmTasks('grunt-contrib-uglify'); +``` + + + + +## Uglify task +_Run this task with the `grunt uglify` command._ + +Task targets, files and options may be specified according to the grunt [Configuring tasks](http://gruntjs.com/configuring-tasks) guide. +### Options + +This task primarily delegates to [UglifyJS2][], so please consider the [UglifyJS documentation][] as required reading for advanced configuration. + +[UglifyJS2]: https://github.com/mishoo/UglifyJS2 +[UglifyJS documentation]: http://lisperator.net/uglifyjs/ + +#### mangle +Type: `Boolean` `Object` +Default: `{}` + +Turn on or off mangling with default options. If an `Object` is specified, it is passed directly to `ast.mangle_names()` *and* `ast.compute_char_frequency()` (mimicking command line behavior). + +#### compress +Type: `Boolean` `Object` +Default: `{}` + +Turn on or off source compression with default options. If an `Object` is specified, it is passed as options to `UglifyJS.Compressor()`. + +#### beautify +Type: `Boolean` `Object` +Default: `false` + +Turns on beautification of the generated source code. An `Object` will be merged and passed with the options sent to `UglifyJS.OutputStream()` + +#### report +Choices: `false` `'min'` `'gzip'` +Default: `false` + +Either do not report anything, report only minification result, or report minification and gzip results. This is useful to see exactly how well Uglify is performing, but using `'gzip'` can add 5-10x runtime task execution. + +Example ouput using `'gzip'`: + +``` +Original: 198444 bytes. +Minified: 101615 bytes. +Gzipped: 20084 bytes. +``` + +#### sourceMap +Type: `Boolean` +Default: `false` + +If `true`, a source map file will be generated in the same directory as the `dest` file. By default it will have the same basename as the `dest` file, but with a `.map` extension. + +#### sourceMapName +Type: `String` `Function` +Default: `undefined` + +To customize the name or location of the generated source map, pass a string to indicate where to write the source map to. If a function is provided, the uglify destination is passed as the argument and the return value will be used as the file name. + +#### sourceMapIn +Type: `String` `Function` +Default: `undefined` + +The location of an input source map from an earlier compilation, e.g. from CoffeeScript. If a function is provided, the +uglify source is passed as the argument and the return value will be used as the sourceMap name. This only makes sense +when there's one source file. + +#### sourceMapIncludeSources +Type: `Boolean` +Default: `false` + +Pass this flag if you want to include the content of source files in the source map as sourcesContent property. + +###### enclose +Type: `Object` +Default: `undefined` + +Wrap all of the code in a closure with a configurable arguments/parameters list. +Each key-value pair in the `enclose` object is effectively an argument-parameter pair. + +#### wrap +Type: `String` +Default: `undefined` + +Wrap all of the code in a closure, an easy way to make sure nothing is leaking. +For variables that need to be public `exports` and `global` variables are made available. +The value of wrap is the global variable exports will be available as. + +#### exportAll +Type: `Boolean` +Default: `false` + +When using `wrap` this will make all global functions and variables available via the export variable. + +#### preserveComments +Type: `Boolean` `String` `Function` +Default: `undefined` +Options: `false` `'all'` `'some'` + +Turn on preservation of comments. + +- `false` will strip all comments +- `'all'` will preserve all comments in code blocks that have not been squashed or dropped +- `'some'` will preserve all comments that start with a bang (`!`) or include a closure compiler style directive (`@preserve` `@license` `@cc_on`) +- `Function` specify your own comment preservation function. You will be passed the current node and the current comment and are expected to return either `true` or `false` + +#### banner +Type: `String` +Default: empty string + +This string will be prepended to the beginning of the minified output. It is processed using [grunt.template.process][], using the default options. + +#### footer +Type: `String` +Default: empty string + +This string will be append to the end of the minified output. It is processed using [grunt.template.process][], using the default options. + +_(Default processing options are explained in the [grunt.template.process][] documentation)_ + +[grunt.template.process]: http://gruntjs.com/api/grunt.template#grunt.template.process + + +### Usage examples + +#### Basic compression + +This configuration will compress and mangle the input files using the default options. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + my_target: { + files: { + 'dest/output.min.js': ['src/input1.js', 'src/input2.js'] + } + } + } +}); +``` + +#### No mangling + +Specify `mangle: false` to prevent changes to your variable and function names. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + options: { + mangle: false + }, + my_target: { + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` + +#### Reserved identifiers + +You can specify identifiers to leave untouched with an `except` array in the `mangle` options. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + options: { + mangle: { + except: ['jQuery', 'Backbone'] + } + }, + my_target: { + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` + +#### Source maps + +Configure basic source map output by specifying a file path for the `sourceMap` option. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + my_target: { + options: { + sourceMap: 'path/to/source-map.js' + }, + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` + +#### Advanced source maps + +You can specify the parameters to pass to `UglifyJS.SourceMap()` which will +allow you to configure advanced settings. + +Refer to the [UglifyJS SourceMap Documentation](http://lisperator.net/uglifyjs/codegen#source-map) for more information. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + my_target: { + options: { + sourceMap: 'path/to/source-map.js', + sourceMapRoot: 'http://example.com/path/to/src/', // the location to find your original source + sourceMapIn: 'example/coffeescript-sourcemap.js', // input sourcemap from a previous compilation + }, + files: { + 'dest/output.min.js': ['src/input.js'], + }, + }, + }, +}); +``` + + +#### Beautify + +Specify `beautify: true` to beautify your code for debugging/troubleshooting purposes. +Pass an object to manually configure any other output options passed directly to `UglifyJS.OutputStream()`. + +See [UglifyJS Codegen documentation](http://lisperator.net/uglifyjs/codegen) for more information. + +_Note that manual configuration will require you to explicitly set `beautify: true` if you want traditional, beautified output._ + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + my_target: { + options: { + beautify: true + }, + files: { + 'dest/output.min.js': ['src/input.js'] + } + }, + my_advanced_target: { + options: { + beautify: { + width: 80, + beautify: true + } + }, + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` + +#### Banner comments + +In this example, running `grunt uglify:my_target` will prepend a banner created by interpolating the `banner` template string with the config object. Here, those properties are the values imported from the `package.json` file (which are available via the `pkg` config property) plus today's date. + +_Note: you don't have to use an external JSON file. It's also valid to create the `pkg` object inline in the config. That being said, if you already have a JSON file, you might as well reference it._ + +```js +// Project configuration. +grunt.initConfig({ + pkg: grunt.file.readJSON('package.json'), + uglify: { + options: { + banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - ' + + '<%= grunt.template.today("yyyy-mm-dd") %> */' + }, + my_target: { + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` + +#### Conditional compilation + +You can also enable UglifyJS conditional compilation. This is commonly used to remove debug code blocks for production builds. + +See [UglifyJS global definitions documentation](http://lisperator.net/uglifyjs/compress#global-defs) for more information. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + options: { + compress: { + global_defs: { + "DEBUG": false + }, + dead_code: true + } + }, + my_target: { + files: { + 'dest/output.min.js': ['src/input.js'] + } + } + } +}); +``` +#### Compiling all files in a folder dynamically + +This configuration will compress and mangle the files dynamically. + +```js +// Project configuration. +grunt.initConfig({ + uglify: { + my_target: { + files: [{ + expand: true, + cwd: 'src/js', + src: '**/*.js', + dest: 'dest/js' + }] + } + } +}); +``` + + +## Release History + + * 2013-01-22   v0.3.2   fix handling of `sourceMapIncludeSources` option. + * 2014-01-20   v0.3.1   fix relative path issue in sourcemaps + * 2014-01-16   v0.3.0   refactor sourcemap support + * 2013-11-09   v0.2.7   prepending banner if sourceMap option not set, addresses + * 2013-11-08   v0.2.6   merged 45, 53, 85 (105 by way of duping 53) Added support for banners in uglified files with sourcemaps Updated docs + * 2013-10-28   v0.2.5   Added warning for banners when using sourcemaps + * 2013-09-02   v0.2.4   updated sourcemap format via /83 + * 2013-06-10   v0.2.3   added footer option + * 2013-05-31   v0.2.2   Reverted /56 due to /58 until [chrome/239660](https://code.google.com/p/chromium/issues/detail?id=239660&q=sourcemappingurl&colspec=ID%20Pri%20M%20Iteration%20ReleaseBlock%20Cr%20Status%20Owner%20Summary%20OS%20Modified) [firefox/870361](https://bugzilla.mozilla.org/show_bug.cgi?id=870361) drop + * 2013-05-22   v0.2.1   Bumped uglify to ~2.3.5 /55 /40 Changed sourcemappingUrl syntax /56 Disabled sorting of names for consistent mangling /44 Updated docs for sourceMapRoot /47 /25 + * 2013-03-14   v0.2.0   No longer report gzip results by default. Support `report` option. + * 2013-01-30   v0.1.2   Added better error reporting Support for dynamic names of multiple sourcemaps + * 2013-02-15   v0.1.1   First official release for Grunt 0.4.0. + * 2013-01-18   v0.1.1rc6   Updating grunt/gruntplugin dependencies to rc6. Changing in-development grunt/gruntplugin dependency versions from tilde version ranges to specific versions. + * 2013-01-09   v0.1.1rc5   Updating to work with grunt v0.4.0rc5. Switching back to this.files api. + * 2012-11-28   v0.1.0   Work in progress, not yet officially released. + +--- + +Task submitted by ["Cowboy" Ben Alman](http://benalman.com) + +*This file was generated on Thu Jan 23 2014 09:31:12.* diff --git a/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs b/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs new file mode 100644 index 0000000..27606b8 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs @@ -0,0 +1,15 @@ +#!/bin/sh +basedir=`dirname "$0"` + +case `uname` in + *CYGWIN*) basedir=`cygpath -w "$basedir"`;; +esac + +if [ -x "$basedir/node" ]; then + "$basedir/node" "$basedir/../uglify-js/bin/uglifyjs" "$@" + ret=$? +else + node "$basedir/../uglify-js/bin/uglifyjs" "$@" + ret=$? +fi +exit $ret diff --git a/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs.cmd b/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs.cmd new file mode 100644 index 0000000..88ff40f --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/.bin/uglifyjs.cmd @@ -0,0 +1,5 @@ +@IF EXIST "%~dp0\node.exe" ( + "%~dp0\node.exe" "%~dp0\..\uglify-js\bin\uglifyjs" %* +) ELSE ( + node "%~dp0\..\uglify-js\bin\uglifyjs" %* +) \ No newline at end of file diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/index.js b/node_modules/grunt-contrib-uglify/node_modules/chalk/index.js new file mode 100644 index 0000000..a21f702 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/index.js @@ -0,0 +1,63 @@ +'use strict'; +var ansi = require('ansi-styles'); +var stripAnsi = require('strip-ansi'); +var hasColor = require('has-color'); +var defineProps = Object.defineProperties; +var chalk = module.exports; + +var styles = (function () { + var ret = {}; + + ansi.grey = ansi.gray; + + Object.keys(ansi).forEach(function (key) { + ret[key] = { + get: function () { + this._styles.push(key); + return this; + } + }; + }); + + return ret; +})(); + +function init() { + var ret = {}; + + Object.keys(styles).forEach(function (name) { + ret[name] = { + get: function () { + var obj = defineProps(function self() { + var str = [].slice.call(arguments).join(' '); + + if (!chalk.enabled) { + return str; + } + + return self._styles.reduce(function (str, name) { + var code = ansi[name]; + return str ? code.open + str + code.close : ''; + }, str); + }, styles); + + obj._styles = []; + + return obj[name]; + } + } + }); + + return ret; +} + +defineProps(chalk, init()); + +chalk.styles = ansi; +chalk.stripColor = stripAnsi; +chalk.supportsColor = hasColor; + +// detect mode if not set manually +if (chalk.enabled === undefined) { + chalk.enabled = chalk.supportsColor; +} diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi new file mode 100644 index 0000000..41efdb3 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi @@ -0,0 +1,15 @@ +#!/bin/sh +basedir=`dirname "$0"` + +case `uname` in + *CYGWIN*) basedir=`cygpath -w "$basedir"`;; +esac + +if [ -x "$basedir/node" ]; then + "$basedir/node" "$basedir/../strip-ansi/cli.js" "$@" + ret=$? +else + node "$basedir/../strip-ansi/cli.js" "$@" + ret=$? +fi +exit $ret diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi.cmd b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi.cmd new file mode 100644 index 0000000..8dc86de --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/.bin/strip-ansi.cmd @@ -0,0 +1,5 @@ +@IF EXIST "%~dp0\node.exe" ( + "%~dp0\node.exe" "%~dp0\..\strip-ansi\cli.js" %* +) ELSE ( + node "%~dp0\..\strip-ansi\cli.js" %* +) \ No newline at end of file diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/ansi-styles.js b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/ansi-styles.js new file mode 100644 index 0000000..3da548c --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/ansi-styles.js @@ -0,0 +1,38 @@ +'use strict'; +var styles = module.exports; + +var codes = { + reset: [0, 0], + + bold: [1, 22], + italic: [3, 23], + underline: [4, 24], + inverse: [7, 27], + strikethrough: [9, 29], + + black: [30, 39], + red: [31, 39], + green: [32, 39], + yellow: [33, 39], + blue: [34, 39], + magenta: [35, 39], + cyan: [36, 39], + white: [37, 39], + gray: [90, 39], + + bgBlack: [40, 49], + bgRed: [41, 49], + bgGreen: [42, 49], + bgYellow: [43, 49], + bgBlue: [44, 49], + bgMagenta: [45, 49], + bgCyan: [46, 49], + bgWhite: [47, 49] +}; + +Object.keys(codes).forEach(function (key) { + var val = codes[key]; + var style = styles[key] = {}; + style.open = '\x1b[' + val[0] + 'm'; + style.close = '\x1b[' + val[1] + 'm'; +}); diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/package.json b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/package.json new file mode 100644 index 0000000..2d61dab --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/package.json @@ -0,0 +1,58 @@ +{ + "name": "ansi-styles", + "version": "1.0.0", + "description": "ANSI escape codes for colorizing strings in the terminal", + "keywords": [ + "ansi", + "styles", + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "tty", + "escape", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "log", + "logging", + "command-line", + "text" + ], + "homepage": "https://github.com/sindresorhus/ansi-styles", + "bugs": { + "url": "https://github.com/sindresorhus/ansi-styles/issues" + }, + "license": "MIT", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "http://sindresorhus.com" + }, + "files": [ + "ansi-styles.js" + ], + "main": "ansi-styles", + "repository": { + "type": "git", + "url": "git://github.com/sindresorhus/ansi-styles.git" + }, + "scripts": { + "test": "mocha" + }, + "devDependencies": { + "mocha": "~1.12.0" + }, + "engines": { + "node": ">=0.8.0" + }, + "readme": "# ansi-styles [![Build Status](https://secure.travis-ci.org/sindresorhus/ansi-styles.png?branch=master)](http://travis-ci.org/sindresorhus/ansi-styles)\n\n> [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for colorizing strings in the terminal.\n\nYou probably want the higher-level [chalk](https://github.com/sindresorhus/chalk) module for styling your strings.\n\n![screenshot](screenshot.png)\n\n\n## Install\n\nInstall with [npm](https://npmjs.org/package/ansi-styles): `npm install --save ansi-styles`\n\n\n## Example\n\n```js\nvar ansi = require('ansi-styles');\n\nconsole.log(ansi.green.open + 'Hello world!' + ansi.green.close);\n```\n\n## API\n\nEach style has an `open` and `close` property.\n\n\n## Styles\n\n### General\n\n- reset\n- bold\n- italic\n- underline\n- inverse\n- strikethrough\n\n### Text colors\n\n- black\n- red\n- green\n- yellow\n- blue\n- magenta\n- cyan\n- white\n- gray\n\n### Background colors\n\n- bgBlack\n- bgRed\n- bgGreen\n- bgYellow\n- bgBlue\n- bgMagenta\n- bgCyan\n- bgWhite\n\n\n## License\n\nMIT © [Sindre Sorhus](http://sindresorhus.com)\n", + "readmeFilename": "readme.md", + "_id": "ansi-styles@1.0.0", + "_from": "ansi-styles@~1.0.0" +} diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/readme.md b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/readme.md new file mode 100644 index 0000000..4ac8cbd --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/ansi-styles/readme.md @@ -0,0 +1,65 @@ +# ansi-styles [![Build Status](https://secure.travis-ci.org/sindresorhus/ansi-styles.png?branch=master)](http://travis-ci.org/sindresorhus/ansi-styles) + +> [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) for colorizing strings in the terminal. + +You probably want the higher-level [chalk](https://github.com/sindresorhus/chalk) module for styling your strings. + +![screenshot](screenshot.png) + + +## Install + +Install with [npm](https://npmjs.org/package/ansi-styles): `npm install --save ansi-styles` + + +## Example + +```js +var ansi = require('ansi-styles'); + +console.log(ansi.green.open + 'Hello world!' + ansi.green.close); +``` + +## API + +Each style has an `open` and `close` property. + + +## Styles + +### General + +- reset +- bold +- italic +- underline +- inverse +- strikethrough + +### Text colors + +- black +- red +- green +- yellow +- blue +- magenta +- cyan +- white +- gray + +### Background colors + +- bgBlack +- bgRed +- bgGreen +- bgYellow +- bgBlue +- bgMagenta +- bgCyan +- bgWhite + + +## License + +MIT © [Sindre Sorhus](http://sindresorhus.com) diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/has-color.js b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/has-color.js new file mode 100644 index 0000000..5a0e4b0 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/has-color.js @@ -0,0 +1,24 @@ +'use strict'; +module.exports = (function () { + if (process.argv.indexOf('--no-color') !== -1) { + return false; + } + + if (process.argv.indexOf('--color') !== -1) { + return true; + } + + if (!process.stdout.isTTY) { + return false; + } + + if (process.platform === 'win32') { + return true; + } + + if ('COLORTERM' in process.env) { + return true; + } + + return /^screen|^xterm|color|ansi|linux/i.test(process.env.TERM); +})(); diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/package.json b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/package.json new file mode 100644 index 0000000..3b42598 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/package.json @@ -0,0 +1,55 @@ +{ + "name": "has-color", + "version": "0.1.3", + "description": "Detect whether a terminal supports color", + "keywords": [ + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "ansi", + "styles", + "tty", + "rgb", + "256", + "shell", + "xterm", + "command-line", + "support", + "capability", + "detect" + ], + "homepage": "https://github.com/sindresorhus/has-color", + "bugs": { + "url": "https://github.com/sindresorhus/has-color/issues" + }, + "license": "MIT", + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "http://sindresorhus.com" + }, + "files": [ + "has-color.js" + ], + "main": "has-color", + "repository": { + "type": "git", + "url": "git://github.com/sindresorhus/has-color.git" + }, + "scripts": { + "test": "mocha" + }, + "devDependencies": { + "mocha": "~1.12.0" + }, + "engines": { + "node": ">=0.8.0" + }, + "readme": "# has-color [![Build Status](https://secure.travis-ci.org/sindresorhus/has-color.png?branch=master)](http://travis-ci.org/sindresorhus/has-color)\n\n> Detect whether a terminal supports color.\n\nUsed in the terminal color module [chalk](https://github.com/sindresorhus/chalk).\n\n\n## Install\n\nInstall with [npm](https://npmjs.org/package/has-color): `npm install --save has-color`\n\n\n## Example\n\n```js\nvar hasColor = require('has-color');\n\nif (hasColor) {\n\tconsole.log('Terminal supports color.');\n}\n```\n\nIt obeys the CLI flags `--color` and `--no-color`.\n\n\n## License\n\nMIT © [Sindre Sorhus](http://sindresorhus.com)\n", + "readmeFilename": "readme.md", + "_id": "has-color@0.1.3", + "_from": "has-color@~0.1.0" +} diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/readme.md b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/readme.md new file mode 100644 index 0000000..0918c85 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/has-color/readme.md @@ -0,0 +1,28 @@ +# has-color [![Build Status](https://secure.travis-ci.org/sindresorhus/has-color.png?branch=master)](http://travis-ci.org/sindresorhus/has-color) + +> Detect whether a terminal supports color. + +Used in the terminal color module [chalk](https://github.com/sindresorhus/chalk). + + +## Install + +Install with [npm](https://npmjs.org/package/has-color): `npm install --save has-color` + + +## Example + +```js +var hasColor = require('has-color'); + +if (hasColor) { + console.log('Terminal supports color.'); +} +``` + +It obeys the CLI flags `--color` and `--no-color`. + + +## License + +MIT © [Sindre Sorhus](http://sindresorhus.com) diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/cli.js b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/cli.js new file mode 100644 index 0000000..f8019cd --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/cli.js @@ -0,0 +1,27 @@ +#!/usr/bin/env node +'use strict'; +var fs = require('fs'); +var strip = require('./index'); +var input = process.argv[2]; + +if (process.argv.indexOf('-h') !== -1 || process.argv.indexOf('--help') !== -1) { + console.log('strip-ansi > '); + console.log('or'); + console.log('cat | strip-ansi > '); + return; +} + +if (process.argv.indexOf('-v') !== -1 || process.argv.indexOf('--version') !== -1) { + console.log(require('./package').version); + return; +} + +if (input) { + process.stdout.write(strip(fs.readFileSync(input, 'utf8'))); + return; +} + +process.stdin.setEncoding('utf8'); +process.stdin.on('data', function (data) { + process.stdout.write(strip(data)); +}); diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/index.js b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/index.js new file mode 100644 index 0000000..62320c5 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/index.js @@ -0,0 +1,4 @@ +'use strict'; +module.exports = function (str) { + return typeof str === 'string' ? str.replace(/\x1B\[([0-9]{1,2}(;[0-9]{1,2})?)?[m|K]/g, '') : str; +}; diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/package.json b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/package.json new file mode 100644 index 0000000..7ca2b5d --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/package.json @@ -0,0 +1,64 @@ +{ + "name": "strip-ansi", + "version": "0.1.1", + "description": "Strip ANSI escape codes (used for colorizing strings in the terminal)", + "license": "MIT", + "bin": { + "strip-ansi": "cli.js" + }, + "repository": { + "type": "git", + "url": "git://github.com/sindresorhus/strip-ansi" + }, + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "http://sindresorhus.com" + }, + "engines": { + "node": ">=0.8.0" + }, + "scripts": { + "test": "mocha" + }, + "files": [ + "index.js", + "cli.js" + ], + "keywords": [ + "strip", + "trim", + "remove", + "ansi", + "styles", + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "tty", + "escape", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "log", + "logging", + "command-line", + "text" + ], + "devDependencies": { + "mocha": "~1.x" + }, + "readme": "# strip-ansi [![Build Status](https://secure.travis-ci.org/sindresorhus/strip-ansi.png?branch=master)](http://travis-ci.org/sindresorhus/strip-ansi)\n\n> Strip [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) (used for colorizing strings in the terminal)\n\nUsed in the terminal color module [chalk](https://github.com/sindresorhus/chalk).\n\n\n## Install\n\nInstall locally with [npm](https://npmjs.org/package/strip-ansi):\n\n```\nnpm install --save strip-ansi\n```\n\nOr globally if you want to use it as a CLI app:\n\n```\nnpm install --global strip-ansi\n```\n\nYou can then use it in your Terminal like:\n\n```\nstrip-ansi file-with-color-codes\n```\n\nOr pipe something to it:\n\n```\nls | strip-ansi\n```\n\n\n## Example\n\n```js\nvar stripAnsi = require('strip-ansi');\nstripAnsi('\\x1b[4mcake\\x1b[0m');\n//=> cake\n```\n\n\n## License\n\nMIT © [Sindre Sorhus](http://sindresorhus.com)\n", + "readmeFilename": "readme.md", + "bugs": { + "url": "https://github.com/sindresorhus/strip-ansi/issues" + }, + "homepage": "https://github.com/sindresorhus/strip-ansi", + "_id": "strip-ansi@0.1.1", + "_from": "strip-ansi@~0.1.0" +} diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/readme.md b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/readme.md new file mode 100644 index 0000000..eb661b3 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/node_modules/strip-ansi/readme.md @@ -0,0 +1,46 @@ +# strip-ansi [![Build Status](https://secure.travis-ci.org/sindresorhus/strip-ansi.png?branch=master)](http://travis-ci.org/sindresorhus/strip-ansi) + +> Strip [ANSI escape codes](http://en.wikipedia.org/wiki/ANSI_escape_code#Colors_and_Styles) (used for colorizing strings in the terminal) + +Used in the terminal color module [chalk](https://github.com/sindresorhus/chalk). + + +## Install + +Install locally with [npm](https://npmjs.org/package/strip-ansi): + +``` +npm install --save strip-ansi +``` + +Or globally if you want to use it as a CLI app: + +``` +npm install --global strip-ansi +``` + +You can then use it in your Terminal like: + +``` +strip-ansi file-with-color-codes +``` + +Or pipe something to it: + +``` +ls | strip-ansi +``` + + +## Example + +```js +var stripAnsi = require('strip-ansi'); +stripAnsi('\x1b[4mcake\x1b[0m'); +//=> cake +``` + + +## License + +MIT © [Sindre Sorhus](http://sindresorhus.com) diff --git a/node_modules/grunt-contrib-uglify/node_modules/chalk/package.json b/node_modules/grunt-contrib-uglify/node_modules/chalk/package.json new file mode 100644 index 0000000..853b014 --- /dev/null +++ b/node_modules/grunt-contrib-uglify/node_modules/chalk/package.json @@ -0,0 +1,61 @@ +{ + "name": "chalk", + "version": "0.4.0", + "description": "Terminal string styling done right. Created because the `colors` module does some really horrible things.", + "license": "MIT", + "repository": { + "type": "git", + "url": "git://github.com/sindresorhus/chalk" + }, + "author": { + "name": "Sindre Sorhus", + "email": "sindresorhus@gmail.com", + "url": "http://sindresorhus.com" + }, + "engines": { + "node": ">=0.8.0" + }, + "scripts": { + "test": "mocha" + }, + "files": [ + "index.js" + ], + "keywords": [ + "color", + "colour", + "colors", + "terminal", + "console", + "cli", + "string", + "ansi", + "styles", + "tty", + "formatting", + "rgb", + "256", + "shell", + "xterm", + "log", + "logging", + "command-line", + "text" + ], + "dependencies": { + "has-color": "~0.1.0", + "ansi-styles": "~1.0.0", + "strip-ansi": "~0.1.0" + }, + "devDependencies": { + "mocha": "~1.x" + }, + "readme": "# \"chalk\"\n\n> Terminal string styling done right\n\n[![Build Status](https://secure.travis-ci.org/sindresorhus/chalk.png?branch=master)](http://travis-ci.org/sindresorhus/chalk)\n\n[colors.js](https://github.com/Marak/colors.js) is currently the most popular string styling module, but it has serious deficiencies like extending String.prototype which causes all kinds of [problems](https://github.com/yeoman/yo/issues/68). Although there are other ones, they either do too much or not enough.\n\n**Chalk is a clean and focused alternative.**\n\n![screenshot](screenshot.png)\n\n\n## Why\n\n- **Doesn't extend String.prototype**\n- Expressive API\n- Clean and focused\n- Auto-detects color support\n- Actively maintained\n- [Used by 150+ modules](https://npmjs.org/browse/depended/chalk)\n\n\n## Install\n\nInstall with [npm](https://npmjs.org/package/chalk): `npm install --save chalk`\n\n\n## Example\n\nChalk comes with an easy to use composable API where you just chain and nest the styles you want.\n\n```js\nvar chalk = require('chalk');\n\n// style a string\nconsole.log( chalk.blue('Hello world!') );\n\n// combine styled and normal strings\nconsole.log( chalk.blue('Hello'), 'World' + chalk.red('!') );\n\n// compose multiple styles using the chainable API\nconsole.log( chalk.blue.bgRed.bold('Hello world!') );\n\n// nest styles\nconsole.log( chalk.red('Hello', chalk.underline.bgBlue('world') + '!') );\n\n// pass in multiple arguments\nconsole.log( chalk.blue('Hello', 'World!', 'Foo', 'bar', 'biz', 'baz') );\n```\n\nYou can easily define your own themes.\n\n```js\nvar chalk = require('chalk');\nvar error = chalk.bold.red;\nconsole.log(error('Error!'));\n```\n\n\n## API\n\n### chalk.`