stylus-source 0.31.0 → 0.32.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (143) hide show
  1. checksums.yaml +7 -0
  2. data/VERSION +1 -1
  3. data/vendor/lib/nodes/unit.js +1 -1
  4. data/vendor/lib/parser.js +0 -1
  5. data/vendor/lib/renderer.js +2 -0
  6. data/vendor/lib/visitor/compiler.js +6 -0
  7. data/vendor/node_modules/cssom/README.mdown +34 -0
  8. data/vendor/node_modules/cssom/package.json +2 -1
  9. data/vendor/node_modules/debug/History.md +15 -0
  10. data/vendor/node_modules/debug/Readme.md +3 -18
  11. data/vendor/node_modules/debug/component.json +9 -0
  12. data/vendor/node_modules/debug/debug.js +10 -2
  13. data/vendor/node_modules/debug/index.js +5 -2
  14. data/vendor/node_modules/debug/lib/debug.js +5 -6
  15. data/vendor/node_modules/debug/package.json +11 -6
  16. data/vendor/node_modules/mkdirp/package.json +6 -9
  17. data/vendor/node_modules/mkdirp/{README.markdown → readme.markdown} +26 -24
  18. data/vendor/node_modules/mocha/History.md +140 -58
  19. data/vendor/node_modules/mocha/LICENSE +2 -2
  20. data/vendor/node_modules/mocha/Makefile +20 -5
  21. data/vendor/node_modules/mocha/Readme.md +110 -22
  22. data/vendor/node_modules/mocha/_mocha.js +574 -182
  23. data/vendor/node_modules/mocha/bin/_mocha +39 -22
  24. data/vendor/node_modules/mocha/bin/mocha +6 -2
  25. data/vendor/node_modules/mocha/component.json +16 -0
  26. data/vendor/node_modules/mocha/lib/browser/debug.js +1 -2
  27. data/vendor/node_modules/mocha/lib/browser/diff.js +287 -0
  28. data/vendor/node_modules/mocha/lib/browser/tty.js +7 -2
  29. data/vendor/node_modules/mocha/lib/hook.js +0 -1
  30. data/vendor/node_modules/mocha/lib/interfaces/bdd.js +3 -3
  31. data/vendor/node_modules/mocha/lib/interfaces/exports.js +5 -5
  32. data/vendor/node_modules/mocha/lib/interfaces/qunit.js +38 -9
  33. data/vendor/node_modules/mocha/lib/interfaces/tdd.js +15 -2
  34. data/vendor/node_modules/mocha/lib/mocha.js +20 -4
  35. data/vendor/node_modules/mocha/lib/reporters/base.js +57 -37
  36. data/vendor/node_modules/mocha/lib/reporters/html.js +2 -4
  37. data/vendor/node_modules/mocha/lib/reporters/json-stream.js +4 -14
  38. data/vendor/node_modules/mocha/lib/reporters/json.js +9 -19
  39. data/vendor/node_modules/mocha/lib/reporters/markdown.js +0 -1
  40. data/vendor/node_modules/mocha/lib/reporters/min.js +2 -2
  41. data/vendor/node_modules/mocha/lib/reporters/nyan.js +33 -39
  42. data/vendor/node_modules/mocha/lib/reporters/tap.js +12 -2
  43. data/vendor/node_modules/mocha/lib/reporters/templates/coverage.jade +3 -3
  44. data/vendor/node_modules/mocha/lib/reporters/templates/menu.jade +1 -1
  45. data/vendor/node_modules/mocha/lib/reporters/xunit.js +4 -4
  46. data/vendor/node_modules/mocha/lib/runnable.js +7 -9
  47. data/vendor/node_modules/mocha/lib/runner.js +24 -9
  48. data/vendor/node_modules/mocha/lib/template.html +2 -1
  49. data/vendor/node_modules/mocha/lib/utils.js +3 -3
  50. data/vendor/node_modules/mocha/mocha.css +37 -13
  51. data/vendor/node_modules/mocha/mocha.js +661 -253
  52. data/vendor/node_modules/mocha/node_modules/commander/package.json +5 -1
  53. data/vendor/node_modules/mocha/node_modules/diff/package.json +5 -1
  54. data/vendor/node_modules/mocha/node_modules/glob/LICENSE +27 -0
  55. data/vendor/node_modules/mocha/node_modules/glob/README.md +250 -0
  56. data/vendor/node_modules/mocha/node_modules/glob/examples/g.js +9 -0
  57. data/vendor/node_modules/mocha/node_modules/glob/examples/usr-local.js +9 -0
  58. data/vendor/node_modules/mocha/node_modules/glob/glob.js +675 -0
  59. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/LICENSE +27 -0
  60. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/README.md +33 -0
  61. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/graceful-fs.js +442 -0
  62. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/package.json +49 -0
  63. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/test/open.js +46 -0
  64. data/vendor/node_modules/mocha/node_modules/glob/node_modules/graceful-fs/test/ulimit.js +158 -0
  65. data/vendor/node_modules/mocha/node_modules/glob/node_modules/inherits/README.md +51 -0
  66. data/vendor/node_modules/mocha/node_modules/glob/node_modules/inherits/inherits.js +29 -0
  67. data/vendor/node_modules/mocha/node_modules/glob/node_modules/inherits/package.json +26 -0
  68. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/LICENSE +23 -0
  69. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/README.md +218 -0
  70. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/minimatch.js +1079 -0
  71. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/AUTHORS +8 -0
  72. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/LICENSE +23 -0
  73. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/README.md +97 -0
  74. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js +257 -0
  75. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/package.json +59 -0
  76. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/s.js +25 -0
  77. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/basic.js +329 -0
  78. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/foreach.js +52 -0
  79. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/memory-leak.js +50 -0
  80. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/LICENSE +27 -0
  81. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/README.md +53 -0
  82. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/bench.js +283 -0
  83. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/package.json +38 -0
  84. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/sigmund.js +39 -0
  85. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/node_modules/sigmund/test/basic.js +24 -0
  86. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/package.json +36 -0
  87. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/test/basic.js +399 -0
  88. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/test/brace-expand.js +33 -0
  89. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/test/caching.js +14 -0
  90. data/vendor/node_modules/mocha/node_modules/glob/node_modules/minimatch/test/defaults.js +274 -0
  91. data/vendor/node_modules/mocha/node_modules/glob/package.json +40 -0
  92. data/vendor/node_modules/mocha/node_modules/glob/test/00-setup.js +176 -0
  93. data/vendor/node_modules/mocha/node_modules/glob/test/bash-comparison.js +63 -0
  94. data/vendor/node_modules/mocha/node_modules/glob/test/bash-results.json +350 -0
  95. data/vendor/node_modules/mocha/node_modules/glob/test/cwd-test.js +55 -0
  96. data/vendor/node_modules/mocha/node_modules/glob/test/globstar-match.js +19 -0
  97. data/vendor/node_modules/mocha/node_modules/glob/test/mark.js +74 -0
  98. data/vendor/node_modules/mocha/node_modules/glob/test/nocase-nomagic.js +113 -0
  99. data/vendor/node_modules/mocha/node_modules/glob/test/pause-resume.js +73 -0
  100. data/vendor/node_modules/mocha/node_modules/glob/test/root-nomount.js +39 -0
  101. data/vendor/node_modules/mocha/node_modules/glob/test/root.js +46 -0
  102. data/vendor/node_modules/mocha/node_modules/glob/test/stat.js +32 -0
  103. data/vendor/node_modules/mocha/node_modules/glob/test/zz-cleanup.js +11 -0
  104. data/vendor/node_modules/mocha/node_modules/growl/History.md +5 -0
  105. data/vendor/node_modules/mocha/node_modules/growl/lib/growl.js +2 -0
  106. data/vendor/node_modules/mocha/node_modules/growl/package.json +7 -3
  107. data/vendor/node_modules/mocha/node_modules/jade/node_modules/mkdirp/package.json +5 -1
  108. data/vendor/node_modules/mocha/node_modules/jade/package.json +5 -1
  109. data/vendor/node_modules/mocha/node_modules/ms/package.json +5 -1
  110. data/vendor/node_modules/mocha/package.json +13 -7
  111. data/vendor/node_modules/mocha/test.js +10 -21
  112. data/vendor/node_modules/should/History.md +5 -0
  113. data/vendor/node_modules/should/Readme.md +172 -172
  114. data/vendor/node_modules/should/lib/eql.js +2 -0
  115. data/vendor/node_modules/should/lib/should.js +4 -3
  116. data/vendor/node_modules/should/package.json +8 -4
  117. data/vendor/node_modules/should/test/should.test.js +27 -0
  118. data/vendor/package.json +1 -1
  119. metadata +61 -35
  120. data/vendor/node_modules/debug/Makefile +0 -4
  121. data/vendor/node_modules/debug/debug.component.js +0 -120
  122. data/vendor/node_modules/debug/head.js +0 -1
  123. data/vendor/node_modules/debug/tail.js +0 -4
  124. data/vendor/node_modules/mocha/node_modules/mkdirp/LICENSE +0 -21
  125. data/vendor/node_modules/mocha/node_modules/mkdirp/README.markdown +0 -61
  126. data/vendor/node_modules/mocha/node_modules/mkdirp/examples/pow.js +0 -6
  127. data/vendor/node_modules/mocha/node_modules/mkdirp/examples/pow.js.orig +0 -6
  128. data/vendor/node_modules/mocha/node_modules/mkdirp/examples/pow.js.rej +0 -19
  129. data/vendor/node_modules/mocha/node_modules/mkdirp/index.js +0 -94
  130. data/vendor/node_modules/mocha/node_modules/mkdirp/package.json +0 -33
  131. data/vendor/node_modules/mocha/node_modules/mkdirp/test/chmod.js +0 -38
  132. data/vendor/node_modules/mocha/node_modules/mkdirp/test/clobber.js +0 -37
  133. data/vendor/node_modules/mocha/node_modules/mkdirp/test/mkdirp.js +0 -28
  134. data/vendor/node_modules/mocha/node_modules/mkdirp/test/perm.js +0 -32
  135. data/vendor/node_modules/mocha/node_modules/mkdirp/test/perm_sync.js +0 -39
  136. data/vendor/node_modules/mocha/node_modules/mkdirp/test/race.js +0 -41
  137. data/vendor/node_modules/mocha/node_modules/mkdirp/test/rel.js +0 -32
  138. data/vendor/node_modules/mocha/node_modules/mkdirp/test/return.js +0 -25
  139. data/vendor/node_modules/mocha/node_modules/mkdirp/test/return_sync.js +0 -24
  140. data/vendor/node_modules/mocha/node_modules/mkdirp/test/root.js +0 -18
  141. data/vendor/node_modules/mocha/node_modules/mkdirp/test/sync.js +0 -32
  142. data/vendor/node_modules/mocha/node_modules/mkdirp/test/umask.js +0 -28
  143. data/vendor/node_modules/mocha/node_modules/mkdirp/test/umask_sync.js +0 -32
@@ -31,5 +31,9 @@
31
31
  "readme": "# Commander.js\n\n The complete solution for [node.js](http://nodejs.org) command-line interfaces, inspired by Ruby's [commander](https://github.com/visionmedia/commander).\n\n [![Build Status](https://secure.travis-ci.org/visionmedia/commander.js.png)](http://travis-ci.org/visionmedia/commander.js)\n\n## Installation\n\n $ npm install commander\n\n## Option parsing\n\n Options with commander are defined with the `.option()` method, also serving as documentation for the options. The example below parses args and options from `process.argv`, leaving remaining args as the `program.args` array which were not consumed by options.\n\n```js\n#!/usr/bin/env node\n\n/**\n * Module dependencies.\n */\n\nvar program = require('commander');\n\nprogram\n .version('0.0.1')\n .option('-p, --peppers', 'Add peppers')\n .option('-P, --pineapple', 'Add pineapple')\n .option('-b, --bbq', 'Add bbq sauce')\n .option('-c, --cheese [type]', 'Add the specified type of cheese [marble]', 'marble')\n .parse(process.argv);\n\nconsole.log('you ordered a pizza with:');\nif (program.peppers) console.log(' - peppers');\nif (program.pineapple) console.log(' - pineappe');\nif (program.bbq) console.log(' - bbq');\nconsole.log(' - %s cheese', program.cheese);\n```\n\n Short flags may be passed as a single arg, for example `-abc` is equivalent to `-a -b -c`. Multi-word options such as \"--template-engine\" are camel-cased, becoming `program.templateEngine` etc.\n\n## Automated --help\n\n The help information is auto-generated based on the information commander already knows about your program, so the following `--help` info is for free:\n\n``` \n $ ./examples/pizza --help\n\n Usage: pizza [options]\n\n Options:\n\n -V, --version output the version number\n -p, --peppers Add peppers\n -P, --pineapple Add pineappe\n -b, --bbq Add bbq sauce\n -c, --cheese <type> Add the specified type of cheese [marble]\n -h, --help output usage information\n\n```\n\n## Coercion\n\n```js\nfunction range(val) {\n return val.split('..').map(Number);\n}\n\nfunction list(val) {\n return val.split(',');\n}\n\nprogram\n .version('0.0.1')\n .usage('[options] <file ...>')\n .option('-i, --integer <n>', 'An integer argument', parseInt)\n .option('-f, --float <n>', 'A float argument', parseFloat)\n .option('-r, --range <a>..<b>', 'A range', range)\n .option('-l, --list <items>', 'A list', list)\n .option('-o, --optional [value]', 'An optional value')\n .parse(process.argv);\n\nconsole.log(' int: %j', program.integer);\nconsole.log(' float: %j', program.float);\nconsole.log(' optional: %j', program.optional);\nprogram.range = program.range || [];\nconsole.log(' range: %j..%j', program.range[0], program.range[1]);\nconsole.log(' list: %j', program.list);\nconsole.log(' args: %j', program.args);\n```\n\n## Custom help\n\n You can display arbitrary `-h, --help` information\n by listening for \"--help\". Commander will automatically\n exit once you are done so that the remainder of your program\n does not execute causing undesired behaviours, for example\n in the following executable \"stuff\" will not output when\n `--help` is used.\n\n```js\n#!/usr/bin/env node\n\n/**\n * Module dependencies.\n */\n\nvar program = require('../');\n\nfunction list(val) {\n return val.split(',').map(Number);\n}\n\nprogram\n .version('0.0.1')\n .option('-f, --foo', 'enable some foo')\n .option('-b, --bar', 'enable some bar')\n .option('-B, --baz', 'enable some baz');\n\n// must be before .parse() since\n// node's emit() is immediate\n\nprogram.on('--help', function(){\n console.log(' Examples:');\n console.log('');\n console.log(' $ custom-help --help');\n console.log(' $ custom-help -h');\n console.log('');\n});\n\nprogram.parse(process.argv);\n\nconsole.log('stuff');\n```\n\nyielding the following help output:\n\n```\n\nUsage: custom-help [options]\n\nOptions:\n\n -h, --help output usage information\n -V, --version output the version number\n -f, --foo enable some foo\n -b, --bar enable some bar\n -B, --baz enable some baz\n\nExamples:\n\n $ custom-help --help\n $ custom-help -h\n\n```\n\n## .prompt(msg, fn)\n\n Single-line prompt:\n\n```js\nprogram.prompt('name: ', function(name){\n console.log('hi %s', name);\n});\n```\n\n Multi-line prompt:\n\n```js\nprogram.prompt('description:', function(name){\n console.log('hi %s', name);\n});\n```\n\n Coercion:\n\n```js\nprogram.prompt('Age: ', Number, function(age){\n console.log('age: %j', age);\n});\n```\n\n```js\nprogram.prompt('Birthdate: ', Date, function(date){\n console.log('date: %s', date);\n});\n```\n\n## .password(msg[, mask], fn)\n\nPrompt for password without echoing:\n\n```js\nprogram.password('Password: ', function(pass){\n console.log('got \"%s\"', pass);\n process.stdin.destroy();\n});\n```\n\nPrompt for password with mask char \"*\":\n\n```js\nprogram.password('Password: ', '*', function(pass){\n console.log('got \"%s\"', pass);\n process.stdin.destroy();\n});\n```\n\n## .confirm(msg, fn)\n\n Confirm with the given `msg`:\n\n```js\nprogram.confirm('continue? ', function(ok){\n console.log(' got %j', ok);\n});\n```\n\n## .choose(list, fn)\n\n Let the user choose from a `list`:\n\n```js\nvar list = ['tobi', 'loki', 'jane', 'manny', 'luna'];\n\nconsole.log('Choose the coolest pet:');\nprogram.choose(list, function(i){\n console.log('you chose %d \"%s\"', i, list[i]);\n});\n```\n\n## Links\n\n - [API documentation](http://visionmedia.github.com/commander.js/)\n - [ascii tables](https://github.com/LearnBoost/cli-table)\n - [progress bars](https://github.com/visionmedia/node-progress)\n - [more progress bars](https://github.com/substack/node-multimeter)\n - [examples](https://github.com/visionmedia/commander.js/tree/master/examples)\n\n## License \n\n(The MIT License)\n\nCopyright (c) 2011 TJ Holowaychuk &lt;tj@vision-media.ca&gt;\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n'Software'), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.",
32
32
  "readmeFilename": "Readme.md",
33
33
  "_id": "commander@0.6.1",
34
- "_from": "commander@0.6.1"
34
+ "dist": {
35
+ "shasum": "c6860472593282da408441578d3550e16fc313f1"
36
+ },
37
+ "_from": "commander@0.6.1",
38
+ "_resolved": "https://registry.npmjs.org/commander/-/commander-0.6.1.tgz"
35
39
  }
@@ -39,5 +39,9 @@
39
39
  "readme": "# jsdiff\n\nA javascript text differencing implementation.\n\nBased on the algorithm proposed in\n[\"An O(ND) Difference Algorithm and its Variations\" (Myers, 1986)](http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.4.6927).\n\n## Installation\n\n npm install diff\n\nor\n\n git clone git://github.com/kpdecker/jsdiff.git\n\n## API\n\n* JsDiff.diffChars(oldStr, newStr)\n Diffs two blocks of text, comparing character by character.\n\n Returns a list of change objects (See below).\n\n* JsDiff.diffWords(oldStr, newStr)\n Diffs two blocks of text, comparing word by word.\n\n Returns a list of change objects (See below).\n\n* JsDiff.diffLines(oldStr, newStr)\n Diffs two blocks of text, comparing line by line.\n\n Returns a list of change objects (See below).\n\n* JsDiff.diffCss(oldStr, newStr)\n Diffs two blocks of text, comparing CSS tokens.\n\n Returns a list of change objects (See below).\n\n* JsDiff.createPatch(fileName, oldStr, newStr, oldHeader, newHeader)\n Creates a unified diff patch.\n\n Parameters:\n * fileName : String to be output in the filename sections of the patch\n * oldStr : Original string value\n * newStr : New string value\n * oldHeader : Additional information to include in the old file header\n * newHeader : Additional information to include in thew new file header\n\n* convertChangesToXML(changes)\n Converts a list of changes to a serialized XML format\n\n### Change Objects\nMany of the methods above return change objects. These objects are consist of the following fields:\n\n* value: Text content\n* added: True if the value was inserted into the new string\n* removed: True of the value was removed from the old string\n\nNote that some cases may omit a particular flag field. Comparison on the flag fields should always be done in a truthy or falsy manner.\n\n## [Example](http://kpdecker.github.com/jsdiff)\n\n## License\n\nSoftware License Agreement (BSD License)\n\nCopyright (c) 2009-2011, Kevin Decker kpdecker@gmail.com\n\nAll rights reserved.\n\nRedistribution and use of this software in source and binary forms, with or without modification,\nare permitted provided that the following conditions are met:\n\n* Redistributions of source code must retain the above\n copyright notice, this list of conditions and the\n following disclaimer.\n\n* Redistributions in binary form must reproduce the above\n copyright notice, this list of conditions and the\n following disclaimer in the documentation and/or other\n materials provided with the distribution.\n\n* Neither the name of Kevin Decker nor the names of its\n contributors may be used to endorse or promote products\n derived from this software without specific prior\n written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR\nIMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND\nFITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR\nCONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\nDATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER\nIN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT\nOF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n",
40
40
  "readmeFilename": "README.md",
41
41
  "_id": "diff@1.0.2",
42
- "_from": "diff@1.0.2"
42
+ "dist": {
43
+ "shasum": "a83d26247f6b41ddfb6cda3f77332af2ae8e4fba"
44
+ },
45
+ "_from": "diff@1.0.2",
46
+ "_resolved": "https://registry.npmjs.org/diff/-/diff-1.0.2.tgz"
43
47
  }
@@ -0,0 +1,27 @@
1
+ Copyright (c) Isaac Z. Schlueter ("Author")
2
+ All rights reserved.
3
+
4
+ The BSD License
5
+
6
+ Redistribution and use in source and binary forms, with or without
7
+ modification, are permitted provided that the following conditions
8
+ are met:
9
+
10
+ 1. Redistributions of source code must retain the above copyright
11
+ notice, this list of conditions and the following disclaimer.
12
+
13
+ 2. Redistributions in binary form must reproduce the above copyright
14
+ notice, this list of conditions and the following disclaimer in the
15
+ documentation and/or other materials provided with the distribution.
16
+
17
+ THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
19
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
20
+ PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
21
+ BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
22
+ CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
23
+ SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
24
+ BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
25
+ WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
26
+ OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
27
+ IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
@@ -0,0 +1,250 @@
1
+ # Glob
2
+
3
+ Match files using the patterns the shell uses, like stars and stuff.
4
+
5
+ This is a glob implementation in JavaScript. It uses the `minimatch`
6
+ library to do its matching.
7
+
8
+ ## Attention: node-glob users!
9
+
10
+ The API has changed dramatically between 2.x and 3.x. This library is
11
+ now 100% JavaScript, and the integer flags have been replaced with an
12
+ options object.
13
+
14
+ Also, there's an event emitter class, proper tests, and all the other
15
+ things you've come to expect from node modules.
16
+
17
+ And best of all, no compilation!
18
+
19
+ ## Usage
20
+
21
+ ```javascript
22
+ var glob = require("glob")
23
+
24
+ // options is optional
25
+ glob("**/*.js", options, function (er, files) {
26
+ // files is an array of filenames.
27
+ // If the `nonull` option is set, and nothing
28
+ // was found, then files is ["**/*.js"]
29
+ // er is an error object or null.
30
+ })
31
+ ```
32
+
33
+ ## Features
34
+
35
+ Please see the [minimatch
36
+ documentation](https://github.com/isaacs/minimatch) for more details.
37
+
38
+ Supports these glob features:
39
+
40
+ * Brace Expansion
41
+ * Extended glob matching
42
+ * "Globstar" `**` matching
43
+
44
+ See:
45
+
46
+ * `man sh`
47
+ * `man bash`
48
+ * `man 3 fnmatch`
49
+ * `man 5 gitignore`
50
+ * [minimatch documentation](https://github.com/isaacs/minimatch)
51
+
52
+ ## glob(pattern, [options], cb)
53
+
54
+ * `pattern` {String} Pattern to be matched
55
+ * `options` {Object}
56
+ * `cb` {Function}
57
+ * `err` {Error | null}
58
+ * `matches` {Array<String>} filenames found matching the pattern
59
+
60
+ Perform an asynchronous glob search.
61
+
62
+ ## glob.sync(pattern, [options])
63
+
64
+ * `pattern` {String} Pattern to be matched
65
+ * `options` {Object}
66
+ * return: {Array<String>} filenames found matching the pattern
67
+
68
+ Perform a synchronous glob search.
69
+
70
+ ## Class: glob.Glob
71
+
72
+ Create a Glob object by instanting the `glob.Glob` class.
73
+
74
+ ```javascript
75
+ var Glob = require("glob").Glob
76
+ var mg = new Glob(pattern, options, cb)
77
+ ```
78
+
79
+ It's an EventEmitter, and starts walking the filesystem to find matches
80
+ immediately.
81
+
82
+ ### new glob.Glob(pattern, [options], [cb])
83
+
84
+ * `pattern` {String} pattern to search for
85
+ * `options` {Object}
86
+ * `cb` {Function} Called when an error occurs, or matches are found
87
+ * `err` {Error | null}
88
+ * `matches` {Array<String>} filenames found matching the pattern
89
+
90
+ Note that if the `sync` flag is set in the options, then matches will
91
+ be immediately available on the `g.found` member.
92
+
93
+ ### Properties
94
+
95
+ * `minimatch` The minimatch object that the glob uses.
96
+ * `options` The options object passed in.
97
+ * `error` The error encountered. When an error is encountered, the
98
+ glob object is in an undefined state, and should be discarded.
99
+ * `aborted` Boolean which is set to true when calling `abort()`. There
100
+ is no way at this time to continue a glob search after aborting, but
101
+ you can re-use the statCache to avoid having to duplicate syscalls.
102
+ * `statCache` Collection of all the stat results the glob search
103
+ performed.
104
+ * `cache` Convenience object. Each field has the following possible
105
+ values:
106
+ * `false` - Path does not exist
107
+ * `true` - Path exists
108
+ * `1` - Path exists, and is not a directory
109
+ * `2` - Path exists, and is a directory
110
+ * `[file, entries, ...]` - Path exists, is a directory, and the
111
+ array value is the results of `fs.readdir`
112
+
113
+ ### Events
114
+
115
+ * `end` When the matching is finished, this is emitted with all the
116
+ matches found. If the `nonull` option is set, and no match was found,
117
+ then the `matches` list contains the original pattern. The matches
118
+ are sorted, unless the `nosort` flag is set.
119
+ * `match` Every time a match is found, this is emitted with the matched.
120
+ * `error` Emitted when an unexpected error is encountered, or whenever
121
+ any fs error occurs if `options.strict` is set.
122
+ * `abort` When `abort()` is called, this event is raised.
123
+
124
+ ### Methods
125
+
126
+ * `abort` Stop the search.
127
+
128
+ ### Options
129
+
130
+ All the options that can be passed to Minimatch can also be passed to
131
+ Glob to change pattern matching behavior. Also, some have been added,
132
+ or have glob-specific ramifications.
133
+
134
+ All options are false by default, unless otherwise noted.
135
+
136
+ All options are added to the glob object, as well.
137
+
138
+ * `cwd` The current working directory in which to search. Defaults
139
+ to `process.cwd()`.
140
+ * `root` The place where patterns starting with `/` will be mounted
141
+ onto. Defaults to `path.resolve(options.cwd, "/")` (`/` on Unix
142
+ systems, and `C:\` or some such on Windows.)
143
+ * `dot` Include `.dot` files in normal matches and `globstar` matches.
144
+ Note that an explicit dot in a portion of the pattern will always
145
+ match dot files.
146
+ * `nomount` By default, a pattern starting with a forward-slash will be
147
+ "mounted" onto the root setting, so that a valid filesystem path is
148
+ returned. Set this flag to disable that behavior.
149
+ * `mark` Add a `/` character to directory matches. Note that this
150
+ requires additional stat calls.
151
+ * `nosort` Don't sort the results.
152
+ * `stat` Set to true to stat *all* results. This reduces performance
153
+ somewhat, and is completely unnecessary, unless `readdir` is presumed
154
+ to be an untrustworthy indicator of file existence. It will cause
155
+ ELOOP to be triggered one level sooner in the case of cyclical
156
+ symbolic links.
157
+ * `silent` When an unusual error is encountered
158
+ when attempting to read a directory, a warning will be printed to
159
+ stderr. Set the `silent` option to true to suppress these warnings.
160
+ * `strict` When an unusual error is encountered
161
+ when attempting to read a directory, the process will just continue on
162
+ in search of other matches. Set the `strict` option to raise an error
163
+ in these cases.
164
+ * `cache` See `cache` property above. Pass in a previously generated
165
+ cache object to save some fs calls.
166
+ * `statCache` A cache of results of filesystem information, to prevent
167
+ unnecessary stat calls. While it should not normally be necessary to
168
+ set this, you may pass the statCache from one glob() call to the
169
+ options object of another, if you know that the filesystem will not
170
+ change between calls. (See "Race Conditions" below.)
171
+ * `sync` Perform a synchronous glob search.
172
+ * `nounique` In some cases, brace-expanded patterns can result in the
173
+ same file showing up multiple times in the result set. By default,
174
+ this implementation prevents duplicates in the result set.
175
+ Set this flag to disable that behavior.
176
+ * `nonull` Set to never return an empty set, instead returning a set
177
+ containing the pattern itself. This is the default in glob(3).
178
+ * `nocase` Perform a case-insensitive match. Note that case-insensitive
179
+ filesystems will sometimes result in glob returning results that are
180
+ case-insensitively matched anyway, since readdir and stat will not
181
+ raise an error.
182
+ * `debug` Set to enable debug logging in minimatch and glob.
183
+ * `globDebug` Set to enable debug logging in glob, but not minimatch.
184
+
185
+ ## Comparisons to other fnmatch/glob implementations
186
+
187
+ While strict compliance with the existing standards is a worthwhile
188
+ goal, some discrepancies exist between node-glob and other
189
+ implementations, and are intentional.
190
+
191
+ If the pattern starts with a `!` character, then it is negated. Set the
192
+ `nonegate` flag to suppress this behavior, and treat leading `!`
193
+ characters normally. This is perhaps relevant if you wish to start the
194
+ pattern with a negative extglob pattern like `!(a|B)`. Multiple `!`
195
+ characters at the start of a pattern will negate the pattern multiple
196
+ times.
197
+
198
+ If a pattern starts with `#`, then it is treated as a comment, and
199
+ will not match anything. Use `\#` to match a literal `#` at the
200
+ start of a line, or set the `nocomment` flag to suppress this behavior.
201
+
202
+ The double-star character `**` is supported by default, unless the
203
+ `noglobstar` flag is set. This is supported in the manner of bsdglob
204
+ and bash 4.1, where `**` only has special significance if it is the only
205
+ thing in a path part. That is, `a/**/b` will match `a/x/y/b`, but
206
+ `a/**b` will not.
207
+
208
+ If an escaped pattern has no matches, and the `nonull` flag is set,
209
+ then glob returns the pattern as-provided, rather than
210
+ interpreting the character escapes. For example,
211
+ `glob.match([], "\\*a\\?")` will return `"\\*a\\?"` rather than
212
+ `"*a?"`. This is akin to setting the `nullglob` option in bash, except
213
+ that it does not resolve escaped pattern characters.
214
+
215
+ If brace expansion is not disabled, then it is performed before any
216
+ other interpretation of the glob pattern. Thus, a pattern like
217
+ `+(a|{b),c)}`, which would not be valid in bash or zsh, is expanded
218
+ **first** into the set of `+(a|b)` and `+(a|c)`, and those patterns are
219
+ checked for validity. Since those two are valid, matching proceeds.
220
+
221
+ ## Windows
222
+
223
+ **Please only use forward-slashes in glob expressions.**
224
+
225
+ Though windows uses either `/` or `\` as its path separator, only `/`
226
+ characters are used by this glob implementation. You must use
227
+ forward-slashes **only** in glob expressions. Back-slashes will always
228
+ be interpreted as escape characters, not path separators.
229
+
230
+ Results from absolute patterns such as `/foo/*` are mounted onto the
231
+ root setting using `path.join`. On windows, this will by default result
232
+ in `/foo/*` matching `C:\foo\bar.txt`.
233
+
234
+ ## Race Conditions
235
+
236
+ Glob searching, by its very nature, is susceptible to race conditions,
237
+ since it relies on directory walking and such.
238
+
239
+ As a result, it is possible that a file that exists when glob looks for
240
+ it may have been deleted or modified by the time it returns the result.
241
+
242
+ As part of its internal implementation, this program caches all stat
243
+ and readdir calls that it makes, in order to cut down on system
244
+ overhead. However, this also makes it even more susceptible to races,
245
+ especially if the cache or statCache objects are reused between glob
246
+ calls.
247
+
248
+ Users are thus advised not to use a glob result as a guarantee of
249
+ filesystem state in the face of rapid changes. For the vast majority
250
+ of operations, this is never a problem.
@@ -0,0 +1,9 @@
1
+ var Glob = require("../").Glob
2
+
3
+ var pattern = "test/a/**/[cg]/../[cg]"
4
+ console.log(pattern)
5
+
6
+ var mg = new Glob(pattern, {mark: true, sync:true}, function (er, matches) {
7
+ console.log("matches", matches)
8
+ })
9
+ console.log("after")
@@ -0,0 +1,9 @@
1
+ var Glob = require("../").Glob
2
+
3
+ var pattern = "{./*/*,/*,/usr/local/*}"
4
+ console.log(pattern)
5
+
6
+ var mg = new Glob(pattern, {mark: true}, function (er, matches) {
7
+ console.log("matches", matches)
8
+ })
9
+ console.log("after")