diff --git a/php/footer.php b/php/footer.php index e4201ea7..3cf31768 100755 --- a/php/footer.php +++ b/php/footer.php @@ -66,13 +66,4 @@ - - - + diff --git a/server/gulpfile.js b/server/gulpfile.js new file mode 100644 index 00000000..57687f12 --- /dev/null +++ b/server/gulpfile.js @@ -0,0 +1,19 @@ +var gulp = require('gulp'), + gutil = require('gulp-util'), + uglify = require('gulp-uglifyjs'), + concat = require('gulp-concat'); + +gulp.task('js', function () { + gulp.src(['../static/js/*.js', '!../static/js/nochan*', '!../static/js/remotecontroller.js']) + .pipe(uglify({ + mangle: true, + compress: true, + enclose: true + })) + .pipe(concat('main.js')) + .pipe(gulp.dest('../static/build-js')); +}); + +gulp.task('default', function(){ + gulp.watch('../static/js/*.js', ['js']); +}); \ No newline at end of file diff --git a/server/node_modules/.bin/gulp b/server/node_modules/.bin/gulp new file mode 120000 index 00000000..5de73328 --- /dev/null +++ b/server/node_modules/.bin/gulp @@ -0,0 +1 @@ +../gulp/bin/gulp.js \ No newline at end of file diff --git a/server/node_modules/gulp-concat/README.md b/server/node_modules/gulp-concat/README.md new file mode 100644 index 00000000..eac59cdd --- /dev/null +++ b/server/node_modules/gulp-concat/README.md @@ -0,0 +1,108 @@ + + +## Information + +
| Package | gulp-concat | +
| Description | +Concatenates files | +
| Node Version | +>= 0.10 | +
0){if(!i.compareByGeneratedPositions(l,c[h-1]))continue;f+=","}f+=r.encode(l.generatedColumn-t),t=l.generatedColumn,l.source!=null&&(f+=r.encode(this._sources.indexOf(l.source)-a),a=this._sources.indexOf(l.source),f+=r.encode(l.originalLine-1-o),o=l.originalLine-1,f+=r.encode(l.originalColumn-s),s=l.originalColumn,l.name!=null&&(f+=r.encode(this._names.indexOf(l.name)-u),u=this._names.indexOf(l.name)))}return f},u.prototype._generateSourcesContent=function(t,n){return t.map(function(e){if(!this._sourcesContents)return null;n!=null&&(e=i.relative(n,e));var t=i.toSetString(e);return Object.prototype.hasOwnProperty.call(this._sourcesContents,t)?this._sourcesContents[t]:null},this)},u.prototype.toJSON=function(){var t={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(t.file=this._file),this._sourceRoot!=null&&(t.sourceRoot=this._sourceRoot),this._sourcesContents&&(t.sourcesContent=this._generateSourcesContent(t.sources,t.sourceRoot)),t},u.prototype.toString=function(){return JSON.stringify(this.toJSON())},t.SourceMapGenerator=u}),define("source-map/base64-vlq",["require","exports","module","source-map/base64"],function(e,t,n){function a(e){return e<0?(-e<<1)+1:(e<<1)+0}function f(e){var t=(e&1)===1,n=e>>1;return t?-n:n}var r=e("./base64"),i=5,s=1<>>=i,f>0&&(s|=u),n+=r.encode(s);while(f>0);return n},t.decode=function(t,n,s){var a=t.length,l=0,c=0,h,p;do{if(n>=a)throw new Error("Expected more digits in base 64 VLQ value.");p=r.decode(t.charAt(n++)),h=!!(p&u),p&=o,l+=p<through2([ options, ] [ transformFunction ] [, flushFunction ])
+
+Consult the **[stream.Transform](http://nodejs.org/docs/latest/api/stream.html#stream_class_stream_transform)** documentation for the exact rules of the `transformFunction` (i.e. `this._transform`) and the optional `flushFunction` (i.e. `this._flush`).
+
+### options
+
+The options argument is optional and is passed straight through to `stream.Transform`. So you can use `objectMode:true` if you are processing non-binary streams (or just use `through2.obj()`).
+
+The `options` argument is first, unlike standard convention, because if I'm passing in an anonymous function then I'd prefer for the options argument to not get lost at the end of the call:
+
+```js
+fs.createReadStream('/tmp/important.dat')
+ .pipe(through2({ objectMode: true, allowHalfOpen: false },
+ function (chunk, enc, cb) {
+ cb(null, 'wut?') // note we can use the second argument on the callback
+ // to provide data as an alternative to this.push('wut?')
+ }
+ )
+ .pipe(fs.createWriteStream('/tmp/wut.txt'))
+```
+
+### transformFunction
+
+The `transformFunction` must have the following signature: `function (chunk, encoding, callback) {}`. A minimal implementation should call the `callback` function to indicate that the transformation is done, even if that transformation means discarding the chunk.
+
+To queue a new chunk, call `this.push(chunk)`—this can be called as many times as required before the `callback()` if you have multiple pieces to send on.
+
+Alternatively, you may use `callback(err, chunk)` as shorthand for emitting a single chunk or an error.
+
+If you **do not provide a `transformFunction`** then you will get a simple pass-through stream.
+
+### flushFunction
+
+The optional `flushFunction` is provided as the last argument (2nd or 3rd, depending on whether you've supplied options) is called just prior to the stream ending. Can be used to finish up any processing that may be in progress.
+
+```js
+fs.createReadStream('/tmp/important.dat')
+ .pipe(through2(
+ function (chunk, enc, cb) { cb(null, chunk) }, // transform is a noop
+ function (cb) { // flush function
+ this.push('tacking on an extra buffer to the end');
+ cb();
+ }
+ ))
+ .pipe(fs.createWriteStream('/tmp/wut.txt'));
+```
+
+through2.ctor([ options, ] transformFunction[, flushFunction ])
+
+Instead of returning a `stream.Transform` instance, `through2.ctor()` returns a **constructor** for a custom Transform. This is useful when you want to use the same transform logic in multiple instances.
+
+```js
+var FToC = through2.ctor({objectMode: true}, function (record, encoding, callback) {
+ if (record.temp != null && record.unit = "F") {
+ record.temp = ( ( record.temp - 32 ) * 5 ) / 9
+ record.unit = "C"
+ }
+ this.push(record)
+ callback()
+})
+
+// Create instances of FToC like so:
+var converter = new FToC()
+// Or:
+var converter = FToC()
+// Or specify/override options when you instantiate, if you prefer:
+var converter = FToC({objectMode: true})
+```
+
+## See Also
+
+ - [through2-map](https://github.com/brycebaril/through2-map) - Array.prototype.map analog for streams.
+ - [through2-filter](https://github.com/brycebaril/through2-filter) - Array.prototype.filter analog for streams.
+ - [through2-reduce](https://github.com/brycebaril/through2-reduce) - Array.prototype.reduce analog for streams.
+ - [through2-spy](https://github.com/brycebaril/through2-spy) - Wrapper for simple stream.PassThrough spies.
+
+## License
+
+**through2** is Copyright (c) 2013 Rod Vagg [@rvagg](https://twitter.com/rvagg) and licenced under the MIT licence. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE file for more details.
diff --git a/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/.npmignore b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/.npmignore
new file mode 100644
index 00000000..38344f87
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/.npmignore
@@ -0,0 +1,5 @@
+build/
+test/
+examples/
+fs.js
+zlib.js
\ No newline at end of file
diff --git a/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/LICENSE b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/LICENSE
new file mode 100644
index 00000000..e3d4e695
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/LICENSE
@@ -0,0 +1,18 @@
+Copyright Joyent, Inc. and other Node contributors. All rights reserved.
+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/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/README.md b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/README.md
new file mode 100644
index 00000000..3fb3e802
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/README.md
@@ -0,0 +1,15 @@
+# readable-stream
+
+***Node-core streams for userland***
+
+[](https://nodei.co/npm/readable-stream/)
+[](https://nodei.co/npm/readable-stream/)
+
+This package is a mirror of the Streams2 and Streams3 implementations in Node-core.
+
+If you want to guarantee a stable streams base, regardless of what version of Node you, or the users of your libraries are using, use **readable-stream** *only* and avoid the *"stream"* module in Node-core.
+
+**readable-stream** comes in two major versions, v1.0.x and v1.1.x. The former tracks the Streams2 implementation in Node 0.10, including bug-fixes and minor improvements as they are added. The latter tracks Streams3 as it develops in Node 0.11; we will likely see a v1.2.x branch for Node 0.12.
+
+**readable-stream** uses proper patch-level versioning so if you pin to `"~1.0.0"` you’ll get the latest Node 0.10 Streams2 implementation, including any fixes and minor non-breaking improvements. The patch-level versions of 1.0.x and 1.1.x should mirror the patch-level versions of Node-core releases. You should prefer the **1.0.x** releases for now and when you’re ready to start using Streams3, pin to `"~1.1.0"`
+
diff --git a/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/duplex.js b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/duplex.js
new file mode 100644
index 00000000..ca807af8
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/duplex.js
@@ -0,0 +1 @@
+module.exports = require("./lib/_stream_duplex.js")
diff --git a/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/lib/_stream_duplex.js b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/lib/_stream_duplex.js
new file mode 100644
index 00000000..b513d61a
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/node_modules/readable-stream/lib/_stream_duplex.js
@@ -0,0 +1,89 @@
+// Copyright Joyent, Inc. and other Node 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.
+
+// a duplex stream is just a stream that is both readable and writable.
+// Since JS doesn't have multiple prototypal inheritance, this class
+// prototypally inherits from Readable, and then parasitically from
+// Writable.
+
+module.exports = Duplex;
+
+/*through2([ options, ] [ transformFunction ] [, flushFunction ])\n\nConsult the **[stream.Transform](http://nodejs.org/docs/latest/api/stream.html#stream_class_stream_transform)** documentation for the exact rules of the `transformFunction` (i.e. `this._transform`) and the optional `flushFunction` (i.e. `this._flush`).\n\n### options\n\nThe options argument is optional and is passed straight through to `stream.Transform`. So you can use `objectMode:true` if you are processing non-binary streams (or just use `through2.obj()`).\n\nThe `options` argument is first, unlike standard convention, because if I'm passing in an anonymous function then I'd prefer for the options argument to not get lost at the end of the call:\n\n```js\nfs.createReadStream('/tmp/important.dat')\n .pipe(through2({ objectMode: true, allowHalfOpen: false },\n function (chunk, enc, cb) {\n cb(null, 'wut?') // note we can use the second argument on the callback\n // to provide data as an alternative to this.push('wut?')\n }\n )\n .pipe(fs.createWriteStream('/tmp/wut.txt'))\n```\n\n### transformFunction\n\nThe `transformFunction` must have the following signature: `function (chunk, encoding, callback) {}`. A minimal implementation should call the `callback` function to indicate that the transformation is done, even if that transformation means discarding the chunk.\n\nTo queue a new chunk, call `this.push(chunk)`—this can be called as many times as required before the `callback()` if you have multiple pieces to send on.\n\nAlternatively, you may use `callback(err, chunk)` as shorthand for emitting a single chunk or an error.\n\nIf you **do not provide a `transformFunction`** then you will get a simple pass-through stream.\n\n### flushFunction\n\nThe optional `flushFunction` is provided as the last argument (2nd or 3rd, depending on whether you've supplied options) is called just prior to the stream ending. Can be used to finish up any processing that may be in progress.\n\n```js\nfs.createReadStream('/tmp/important.dat')\n .pipe(through2(\n function (chunk, enc, cb) { cb(null, chunk) }, // transform is a noop\n function (cb) { // flush function\n this.push('tacking on an extra buffer to the end');\n cb();\n }\n ))\n .pipe(fs.createWriteStream('/tmp/wut.txt'));\n```\n\nthrough2.ctor([ options, ] transformFunction[, flushFunction ])\n\nInstead of returning a `stream.Transform` instance, `through2.ctor()` returns a **constructor** for a custom Transform. This is useful when you want to use the same transform logic in multiple instances.\n\n```js\nvar FToC = through2.ctor({objectMode: true}, function (record, encoding, callback) {\n if (record.temp != null && record.unit = \"F\") {\n record.temp = ( ( record.temp - 32 ) * 5 ) / 9\n record.unit = \"C\"\n }\n this.push(record)\n callback()\n})\n\n// Create instances of FToC like so:\nvar converter = new FToC()\n// Or:\nvar converter = FToC()\n// Or specify/override options when you instantiate, if you prefer:\nvar converter = FToC({objectMode: true})\n```\n\n## See Also\n\n - [through2-map](https://github.com/brycebaril/through2-map) - Array.prototype.map analog for streams.\n - [through2-filter](https://github.com/brycebaril/through2-filter) - Array.prototype.filter analog for streams.\n - [through2-reduce](https://github.com/brycebaril/through2-reduce) - Array.prototype.reduce analog for streams.\n - [through2-spy](https://github.com/brycebaril/through2-spy) - Wrapper for simple stream.PassThrough spies.\n\n## License\n\n**through2** is Copyright (c) 2013 Rod Vagg [@rvagg](https://twitter.com/rvagg) and licenced under the MIT licence. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE file for more details.\n",
+ "readmeFilename": "README.md",
+ "bugs": {
+ "url": "https://github.com/rvagg/through2/issues"
+ },
+ "_id": "through2@0.6.5",
+ "_from": "through2@>=0.6.1 <1.0.0-0"
+}
diff --git a/server/node_modules/gulp-concat/node_modules/through2/through2.js b/server/node_modules/gulp-concat/node_modules/through2/through2.js
new file mode 100644
index 00000000..5b7a880e
--- /dev/null
+++ b/server/node_modules/gulp-concat/node_modules/through2/through2.js
@@ -0,0 +1,96 @@
+var Transform = require('readable-stream/transform')
+ , inherits = require('util').inherits
+ , xtend = require('xtend')
+
+function DestroyableTransform(opts) {
+ Transform.call(this, opts)
+ this._destroyed = false
+}
+
+inherits(DestroyableTransform, Transform)
+
+DestroyableTransform.prototype.destroy = function(err) {
+ if (this._destroyed) return
+ this._destroyed = true
+
+ var self = this
+ process.nextTick(function() {
+ if (err)
+ self.emit('error', err)
+ self.emit('close')
+ })
+}
+
+// a noop _transform function
+function noop (chunk, enc, callback) {
+ callback(null, chunk)
+}
+
+
+// create a new export function, used by both the main export and
+// the .ctor export, contains common logic for dealing with arguments
+function through2 (construct) {
+ return function (options, transform, flush) {
+ if (typeof options == 'function') {
+ flush = transform
+ transform = options
+ options = {}
+ }
+
+ if (typeof transform != 'function')
+ transform = noop
+
+ if (typeof flush != 'function')
+ flush = null
+
+ return construct(options, transform, flush)
+ }
+}
+
+
+// main export, just make me a transform stream!
+module.exports = through2(function (options, transform, flush) {
+ var t2 = new DestroyableTransform(options)
+
+ t2._transform = transform
+
+ if (flush)
+ t2._flush = flush
+
+ return t2
+})
+
+
+// make me a reusable prototype that I can `new`, or implicitly `new`
+// with a constructor call
+module.exports.ctor = through2(function (options, transform, flush) {
+ function Through2 (override) {
+ if (!(this instanceof Through2))
+ return new Through2(override)
+
+ this.options = xtend(options, override)
+
+ DestroyableTransform.call(this, this.options)
+ }
+
+ inherits(Through2, DestroyableTransform)
+
+ Through2.prototype._transform = transform
+
+ if (flush)
+ Through2.prototype._flush = flush
+
+ return Through2
+})
+
+
+module.exports.obj = through2(function (options, transform, flush) {
+ var t2 = new DestroyableTransform(xtend({ objectMode: true, highWaterMark: 16 }, options))
+
+ t2._transform = transform
+
+ if (flush)
+ t2._flush = flush
+
+ return t2
+})
diff --git a/server/node_modules/gulp-concat/package.json b/server/node_modules/gulp-concat/package.json
new file mode 100644
index 00000000..b5e64778
--- /dev/null
+++ b/server/node_modules/gulp-concat/package.json
@@ -0,0 +1,54 @@
+{
+ "name": "gulp-concat",
+ "description": "Concatenates files",
+ "version": "2.6.0",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/wearefractal/gulp-concat"
+ },
+ "author": {
+ "name": "Fractal",
+ "email": "contact@wearefractal.com",
+ "url": "http://wearefractal.com/"
+ },
+ "files": [
+ "index.js"
+ ],
+ "keywords": [
+ "gulpplugin"
+ ],
+ "dependencies": {
+ "concat-with-sourcemaps": "^1.0.0",
+ "gulp-util": "^3.0.1",
+ "through2": "^0.6.3"
+ },
+ "devDependencies": {
+ "gulp": "^3.8.7",
+ "gulp-sourcemaps": "^1.1.4",
+ "istanbul": "^0.3.2",
+ "mocha": "^2.0.1",
+ "mocha-lcov-reporter": "0.0.1",
+ "should": "^5.0.0",
+ "stream-array": "^1.0.1",
+ "stream-assert": "^2.0.1"
+ },
+ "scripts": {
+ "test": "mocha",
+ "coverage": "istanbul cover _mocha"
+ },
+ "engines": {
+ "node": ">= 0.10"
+ },
+ "license": "MIT",
+ "readme": "\n\n## Information\n\n\n
\n\n## Usage\n\n```js\nvar concat = require('gulp-concat');\n\ngulp.task('scripts', function() {\n return gulp.src('./lib/*.js')\n .pipe(concat('all.js'))\n .pipe(gulp.dest('./dist/'));\n});\n```\n\nThis will concat files by your operating systems newLine. It will take the base directory from the first file that passes through it.\n\nFiles will be concatenated in the order that they are specified in the `gulp.src` function. For example, to concat `./lib/file3.js`, `./lib/file1.js` and `./lib/file2.js` in that order, the following code will create a task to do that:\n\n```js\nvar concat = require('gulp-concat');\n\ngulp.task('scripts', function() {\n return gulp.src(['./lib/file3.js', './lib/file1.js', './lib/file2.js'])\n .pipe(concat('all.js'))\n .pipe(gulp.dest('./dist/'));\n});\n```\n\nTo change the newLine simply pass an object as the second argument to concat with newLine being whatever (\\r\\n if you want to support any OS to look at it)\n\nFor instance:\n\n```js\n.pipe(concat('main.js', {newLine: ';'}))\n```\n\nTo specify `cwd`, `path` and other [vinyl](https://github.com/wearefractal/vinyl) properties, gulp-concat accepts `Object` as first argument:\n\n```js\nvar concat = require('gulp-concat');\n\ngulp.task('scripts', function() {\n return gulp.src(['./lib/file3.js', './lib/file1.js', './lib/file2.js'])\n .pipe(concat({ path: 'new.js', stat: { mode: 0666 }}))\n .pipe(gulp.dest('./dist'));\n});\n```\n\nThis will concat files into `./dist/new.js`.\n\n### Source maps\n\nSource maps can be generated by using [gulp-sourcemaps](https://www.npmjs.org/package/gulp-sourcemaps):\n\n```js\nvar gulp = require('gulp');\nvar concat = require('gulp-concat');\nvar sourcemaps = require('gulp-sourcemaps');\n\ngulp.task('javascript', function() {\n return gulp.src('src/**/*.js')\n .pipe(sourcemaps.init())\n .pipe(concat('all.js'))\n .pipe(sourcemaps.write())\n .pipe(gulp.dest('dist'));\n});\n```\n\n## LICENSE\n\n(MIT License)\n\nCopyright (c) 2014 Fractal \n \nPackage gulp-concat \n\n \nDescription \nConcatenates files \n\n \nNode Version \n>= 0.10 \n
+
+
+## Usage
+
+```javascript
+var gutil = require('gulp-util');
+
+gutil.log('stuff happened', 'Really it did', gutil.colors.magenta('123'));
+gutil.beep();
+
+gutil.replaceExtension('file.coffee', '.js'); // file.js
+
+var opt = {
+ name: 'todd',
+ file: someGulpFile
+};
+gutil.template('test <%= name %> <%= file.path %>', opt) // test todd /js/hi.js
+```
+
+### log(msg...)
+
+Logs stuff. Already prefixed with [gulp] and all that. If you pass in multiple arguments it will join them by a space.
+
+The default gulp coloring using gutil.colors.
+
+Package gulp-util
+
+
+Description
+Utility functions for gulp plugins
+
+
+Node Version
+>= 0.10
+\n\t
\n\n> Terminal string styling done right\n\n[](https://travis-ci.org/sindresorhus/chalk) [](https://www.youtube.com/watch?v=Sm368W0OsHo)\n\n[colors.js](https://github.com/Marak/colors.js) used to be 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\n\n\n## Why\n\n- Highly performant\n- Doesn't extend `String.prototype`\n- Expressive API\n- Ability to nest styles\n- Clean and focused\n- Auto-detects color support\n- Actively maintained\n- [Used by ~3000 modules](https://www.npmjs.com/browse/depended/chalk)\n\n\n## Install\n\n```\n$ npm install --save chalk\n```\n\n\n## Usage\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\nchalk.blue('Hello world!');\n\n// combine styled and normal strings\nchalk.blue('Hello') + 'World' + chalk.red('!');\n\n// compose multiple styles using the chainable API\nchalk.blue.bgRed.bold('Hello world!');\n\n// pass in multiple arguments\nchalk.blue('Hello', 'World!', 'Foo', 'bar', 'biz', 'baz');\n\n// nest styles\nchalk.red('Hello', chalk.underline.bgBlue('world') + '!');\n\n// nest styles of the same type even (color, underline, background)\nchalk.green(\n\t'I am a green line ' +\n\tchalk.blue.underline.bold('with a blue substring') +\n\t' that becomes green again!'\n);\n```\n\nEasily define your own themes.\n\n```js\nvar chalk = require('chalk');\nvar error = chalk.bold.red;\nconsole.log(error('Error!'));\n```\n\nTake advantage of console.log [string substitution](http://nodejs.org/docs/latest/api/console.html#console_console_log_data).\n\n```js\nvar name = 'Sindre';\nconsole.log(chalk.green('Hello %s'), name);\n//=> Hello Sindre\n```\n\n\n## API\n\n### chalk.`
\n\t\n\t
\n\t
\n