snowball 0.1.21 → 0.1.22
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -13
- data/.gitignore +1 -3
- data/{lib/snowball → bin}/roll.js +0 -0
- data/lib/snowball/roller.rb +1 -1
- data/lib/snowball/version.rb +1 -1
- data/node_modules/.bin/browserify +161 -0
- data/node_modules/.bin/cake +7 -0
- data/node_modules/.bin/coffee +7 -0
- data/node_modules/.bin/jade +168 -0
- data/node_modules/browserify/.travis.yml +4 -0
- data/node_modules/browserify/LICENSE +63 -0
- data/node_modules/browserify/README.markdown +172 -0
- data/node_modules/browserify/bin/cmd.js +161 -0
- data/node_modules/browserify/builtins/__browserify_process.js +55 -0
- data/node_modules/browserify/builtins/assert.js +314 -0
- data/node_modules/browserify/builtins/child_process.js +2 -0
- data/node_modules/browserify/builtins/events.js +178 -0
- data/node_modules/browserify/builtins/fs.js +1 -0
- data/node_modules/browserify/builtins/https.js +1 -0
- data/node_modules/browserify/builtins/net.js +1 -0
- data/node_modules/browserify/builtins/path.js +175 -0
- data/node_modules/browserify/builtins/querystring.js +250 -0
- data/node_modules/browserify/builtins/stream.js +119 -0
- data/node_modules/browserify/builtins/string_decoder.js +161 -0
- data/node_modules/browserify/builtins/sys.js +1 -0
- data/node_modules/browserify/builtins/timers.js +39 -0
- data/node_modules/browserify/builtins/tls.js +1 -0
- data/node_modules/browserify/builtins/tty.js +2 -0
- data/node_modules/browserify/builtins/url.js +604 -0
- data/node_modules/browserify/builtins/util.js +351 -0
- data/node_modules/browserify/example/debug/browserify.js +219 -0
- data/node_modules/browserify/example/debug/build.sh +3 -0
- data/node_modules/browserify/example/debug/index.html +7 -0
- data/node_modules/browserify/example/debug/js/entry.js +2 -0
- data/node_modules/browserify/example/debug/js/thrower.js +3 -0
- data/node_modules/browserify/example/debug/server.js +9 -0
- data/node_modules/browserify/example/simple-build/browserify.js +368 -0
- data/node_modules/browserify/example/simple-build/build.sh +3 -0
- data/node_modules/browserify/example/simple-build/index.html +9 -0
- data/node_modules/browserify/example/simple-build/js/bar.js +3 -0
- data/node_modules/browserify/example/simple-build/js/entry.js +5 -0
- data/node_modules/browserify/example/simple-build/js/foo.js +5 -0
- data/node_modules/browserify/example/simple-build/server.js +9 -0
- data/node_modules/browserify/example/test/b.js +5 -0
- data/node_modules/browserify/example/test/bar.js +3 -0
- data/node_modules/browserify/example/test/foo.js +3 -0
- data/node_modules/browserify/example/test/m.js +3 -0
- data/node_modules/browserify/example/test/n.js +3 -0
- data/node_modules/browserify/example/using-http/bundle.js +813 -0
- data/node_modules/browserify/example/using-http/entry.js +25 -0
- data/node_modules/browserify/example/using-http/index.html +9 -0
- data/node_modules/browserify/example/using-http/server.js +28 -0
- data/node_modules/browserify/index.js +202 -0
- data/node_modules/browserify/lib/watch.js +75 -0
- data/node_modules/browserify/lib/wrap.js +580 -0
- data/node_modules/browserify/lib/wrappers.js +10 -0
- data/node_modules/browserify/node_modules/buffer-browserify/.npmignore +1 -0
- data/node_modules/browserify/node_modules/buffer-browserify/README.md +11 -0
- data/node_modules/browserify/node_modules/buffer-browserify/buffer_ieee754.js +84 -0
- data/node_modules/browserify/node_modules/buffer-browserify/index.js +1317 -0
- data/node_modules/browserify/node_modules/buffer-browserify/node_modules/base64-js/README.md +14 -0
- data/node_modules/browserify/node_modules/buffer-browserify/node_modules/base64-js/lib/b64.js +84 -0
- data/node_modules/browserify/node_modules/buffer-browserify/node_modules/base64-js/package.json +30 -0
- data/node_modules/browserify/node_modules/buffer-browserify/node_modules/base64-js/test/runner.js +50 -0
- data/node_modules/browserify/node_modules/buffer-browserify/package.json +46 -0
- data/node_modules/browserify/node_modules/buffer-browserify/test/buffer.js +218 -0
- data/node_modules/browserify/node_modules/commondir/README.markdown +45 -0
- data/node_modules/browserify/node_modules/commondir/example/base.js +3 -0
- data/node_modules/browserify/node_modules/commondir/example/dir.js +3 -0
- data/node_modules/browserify/node_modules/commondir/index.js +29 -0
- data/node_modules/browserify/node_modules/commondir/package.json +47 -0
- data/node_modules/browserify/node_modules/commondir/test/dirs.js +66 -0
- data/node_modules/browserify/node_modules/crypto-browserify/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/crypto-browserify/example/bundle.js +637 -0
- data/node_modules/browserify/node_modules/crypto-browserify/example/index.html +12 -0
- data/node_modules/browserify/node_modules/crypto-browserify/example/test.js +4 -0
- data/node_modules/browserify/node_modules/crypto-browserify/index.js +74 -0
- data/node_modules/browserify/node_modules/crypto-browserify/md5.js +384 -0
- data/node_modules/browserify/node_modules/crypto-browserify/package.json +33 -0
- data/node_modules/browserify/node_modules/crypto-browserify/readme.markdown +20 -0
- data/node_modules/browserify/node_modules/crypto-browserify/rng.js +37 -0
- data/node_modules/browserify/node_modules/crypto-browserify/sha.js +210 -0
- data/node_modules/browserify/node_modules/crypto-browserify/test/simple.js +35 -0
- data/node_modules/browserify/node_modules/deputy/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/deputy/README.markdown +55 -0
- data/node_modules/browserify/node_modules/deputy/example/cache.js +5 -0
- data/node_modules/browserify/node_modules/deputy/index.js +46 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/.npmignore +2 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/.travis.yml +5 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/LICENSE +21 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/examples/pow.js +6 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/index.js +82 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/package.json +34 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/readme.markdown +63 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/chmod.js +38 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/clobber.js +37 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/mkdirp.js +28 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/perm.js +32 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/perm_sync.js +39 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/race.js +41 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/rel.js +32 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/return.js +25 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/return_sync.js +24 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/root.js +18 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/sync.js +32 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/umask.js +28 -0
- data/node_modules/browserify/node_modules/deputy/node_modules/mkdirp/test/umask_sync.js +32 -0
- data/node_modules/browserify/node_modules/deputy/package.json +47 -0
- data/node_modules/browserify/node_modules/deputy/test/cache.js +58 -0
- data/node_modules/browserify/node_modules/detective/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/detective/README.markdown +66 -0
- data/node_modules/browserify/node_modules/detective/example/strings.js +6 -0
- data/node_modules/browserify/node_modules/detective/example/strings_src.js +3 -0
- data/node_modules/browserify/node_modules/detective/index.js +60 -0
- data/node_modules/browserify/node_modules/detective/node_modules/.bin/esparse +42 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/.travis.yml +5 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/LICENSE.BSD +19 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/README.md +74 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/codemirror/codemirror.css +112 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/codemirror/codemirror.js +2972 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/codemirror/javascript.js +360 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/json2.js +487 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/style.css +164 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/yui/treeview-min.js +12 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/yui/treeview-sprite.gif +0 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/yui/treeview.css +7 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/assets/yui/yahoo-dom-event.js +14 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/bin/esparse.js +42 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/changes +92 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/cm +696 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/checkenv.js +42 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/collector.html +82 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/collector.js +170 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/functiontrace.html +106 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/functiontrace.js +123 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/parse.css +82 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/parse.html +352 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/precedence.html +225 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/rewrite.html +120 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/demo/rewrite.js +71 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/esprima.js +3577 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/index.html +103 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/package.json +42 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/Tokenizer.js +646 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/XMLHttpRequest.js +509 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/ZeParser.js +2185 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/backbone-0.5.3.js +1158 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/benchmark.js +3261 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/escodegen.js +906 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/esmorph.js +240 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/ext-core-3.0.0.js +6579 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/ext-core-3.1.0.js +10255 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jquery-1.6.4.js +9046 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jquery-1.7.1.js +9266 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jquery.mobile-1.0.js +6951 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jsdefs.js +731 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jslex.js +588 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/jsparse.js +1921 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/mootools-1.3.2.js +5952 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/mootools-1.4.1.js +6297 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/parse-js.js +1342 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/platform.js +878 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/prototype-1.6.1.js +4874 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/prototype-1.7.0.0.js +6082 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/3rdparty/underscore-1.2.3.js +981 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/benchmarks.html +58 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/benchmarks.js +328 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/compare.html +140 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/compare.js +270 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/compat.html +40 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/compat.js +239 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/coverage.footer.html +3 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/coverage.header.html +37 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/coverage.html +3617 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/index.html +36 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/reflect.js +403 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/run.js +66 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/test/test.js +16659 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/tools/generate-unicode-regex.py +164 -0
- data/node_modules/browserify/node_modules/detective/node_modules/esprima/tools/update-coverage.sh +28 -0
- data/node_modules/browserify/node_modules/detective/package.json +47 -0
- data/node_modules/browserify/node_modules/detective/test/both.js +11 -0
- data/node_modules/browserify/node_modules/detective/test/chained.js +9 -0
- data/node_modules/browserify/node_modules/detective/test/files/both.js +4 -0
- data/node_modules/browserify/node_modules/detective/test/files/chained.js +5 -0
- data/node_modules/browserify/node_modules/detective/test/files/nested.js +22 -0
- data/node_modules/browserify/node_modules/detective/test/files/skip.js +7 -0
- data/node_modules/browserify/node_modules/detective/test/files/strings.js +13 -0
- data/node_modules/browserify/node_modules/detective/test/files/word.js +13 -0
- data/node_modules/browserify/node_modules/detective/test/nested.js +9 -0
- data/node_modules/browserify/node_modules/detective/test/skip.js +9 -0
- data/node_modules/browserify/node_modules/detective/test/strings.js +9 -0
- data/node_modules/browserify/node_modules/detective/test/word.js +12 -0
- data/node_modules/browserify/node_modules/http-browserify/.npmignore +1 -0
- data/node_modules/browserify/node_modules/http-browserify/example/get/index.html +9 -0
- data/node_modules/browserify/node_modules/http-browserify/example/get/main.js +14 -0
- data/node_modules/browserify/node_modules/http-browserify/example/get/server.js +12 -0
- data/node_modules/browserify/node_modules/http-browserify/example/headers/index.html +9 -0
- data/node_modules/browserify/node_modules/http-browserify/example/headers/main.js +18 -0
- data/node_modules/browserify/node_modules/http-browserify/example/headers/server.js +15 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/data.json +139 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/index.html +9 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/main.js +13 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/.npmignore +2 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/LICENSE.APACHE2 +15 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/LICENSE.MIT +24 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/examples/all_docs.js +13 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/index.js +189 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/LICENSE +24 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/README.markdown +11 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/bench.js +26 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/examples/twitterfeed.js +30 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/jsonparse.js +379 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/package.json +36 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/samplejson/basic.json +167 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/samplejson/basic2.json +180 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/test/primitives.js +54 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/node_modules/jsonparse/test/utf8.js +38 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/package.json +40 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/readme.markdown +145 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/bool.js +41 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/destroy_missing.js +22 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/empty.js +44 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/fixtures/all_npm.json +4030 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/fn.js +39 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/memory.js +69 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/multiple_objects.js +42 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/multiple_objects_error.js +35 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/parsejson.js +28 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/stringify.js +41 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/stringify_object.js +47 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/test.js +35 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/test2.js +29 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/node_modules/JSONStream/test/two-ways.js +41 -0
- data/node_modules/browserify/node_modules/http-browserify/example/json-stream/server.js +10 -0
- data/node_modules/browserify/node_modules/http-browserify/example/post/index.html +9 -0
- data/node_modules/browserify/node_modules/http-browserify/example/post/main.js +16 -0
- data/node_modules/browserify/node_modules/http-browserify/example/post/server.js +19 -0
- data/node_modules/browserify/node_modules/http-browserify/example/streaming/index.html +9 -0
- data/node_modules/browserify/node_modules/http-browserify/example/streaming/main.js +16 -0
- data/node_modules/browserify/node_modules/http-browserify/example/streaming/server.js +21 -0
- data/node_modules/browserify/node_modules/http-browserify/index.js +59 -0
- data/node_modules/browserify/node_modules/http-browserify/lib/request.js +128 -0
- data/node_modules/browserify/node_modules/http-browserify/lib/response.js +119 -0
- data/node_modules/browserify/node_modules/http-browserify/node_modules/concat-stream/index.js +48 -0
- data/node_modules/browserify/node_modules/http-browserify/node_modules/concat-stream/package.json +30 -0
- data/node_modules/browserify/node_modules/http-browserify/node_modules/concat-stream/readme.md +31 -0
- data/node_modules/browserify/node_modules/http-browserify/node_modules/concat-stream/test.js +34 -0
- data/node_modules/browserify/node_modules/http-browserify/package.json +46 -0
- data/node_modules/browserify/node_modules/http-browserify/readme.markdown +128 -0
- data/node_modules/browserify/node_modules/nub/README.markdown +23 -0
- data/node_modules/browserify/node_modules/nub/index.js +64 -0
- data/node_modules/browserify/node_modules/nub/package.json +46 -0
- data/node_modules/browserify/node_modules/nub/test/by.js +51 -0
- data/node_modules/browserify/node_modules/nub/test/nub.js +46 -0
- data/node_modules/browserify/node_modules/resolve/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/resolve/LICENSE +18 -0
- data/node_modules/browserify/node_modules/resolve/README.markdown +47 -0
- data/node_modules/browserify/node_modules/resolve/index.js +106 -0
- data/node_modules/browserify/node_modules/resolve/package.json +45 -0
- data/node_modules/browserify/node_modules/resolve/test/core.js +12 -0
- data/node_modules/browserify/node_modules/resolve/test/filter.js +15 -0
- data/node_modules/browserify/node_modules/resolve/test/mock.js +64 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver.js +157 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/bar/node_modules/foo/index.js +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/baz/doom.js +0 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/baz/package.json +3 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/baz/quux.js +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/biz/node_modules/grux/index.js +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/biz/node_modules/tiv/index.js +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/cup.coffee +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/foo.js +1 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/mug.coffee +0 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/mug.js +0 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/other_path/lib/other-lib.js +0 -0
- data/node_modules/browserify/node_modules/resolve/test/resolver/other_path/root.js +0 -0
- data/node_modules/browserify/node_modules/syntax-error/.travis.yml +4 -0
- data/node_modules/browserify/node_modules/syntax-error/LICENSE +18 -0
- data/node_modules/browserify/node_modules/syntax-error/example/check.js +12 -0
- data/node_modules/browserify/node_modules/syntax-error/example/src.js +9 -0
- data/node_modules/browserify/node_modules/syntax-error/index.js +54 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/.bin/esparse +42 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/.travis.yml +5 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/LICENSE.BSD +19 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/README.md +74 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/codemirror/codemirror.css +112 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/codemirror/codemirror.js +2972 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/codemirror/javascript.js +360 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/json2.js +487 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/style.css +164 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/yui/treeview-min.js +12 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/yui/treeview-sprite.gif +0 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/yui/treeview.css +7 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/assets/yui/yahoo-dom-event.js +14 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/bin/esparse.js +42 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/changes +92 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/cm +696 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/checkenv.js +42 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/collector.html +82 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/collector.js +170 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/functiontrace.html +106 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/functiontrace.js +123 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/parse.css +82 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/parse.html +352 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/precedence.html +225 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/rewrite.html +120 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/demo/rewrite.js +71 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/esprima.js +3577 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/index.html +103 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/package.json +42 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/Tokenizer.js +646 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/XMLHttpRequest.js +509 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/ZeParser.js +2185 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/backbone-0.5.3.js +1158 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/benchmark.js +3261 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/escodegen.js +906 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/esmorph.js +240 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/ext-core-3.0.0.js +6579 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/ext-core-3.1.0.js +10255 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jquery-1.6.4.js +9046 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jquery-1.7.1.js +9266 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jquery.mobile-1.0.js +6951 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jsdefs.js +731 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jslex.js +588 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/jsparse.js +1921 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/mootools-1.3.2.js +5952 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/mootools-1.4.1.js +6297 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/parse-js.js +1342 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/platform.js +878 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/prototype-1.6.1.js +4874 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/prototype-1.7.0.0.js +6082 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/3rdparty/underscore-1.2.3.js +981 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/benchmarks.html +58 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/benchmarks.js +328 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/compare.html +140 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/compare.js +270 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/compat.html +40 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/compat.js +239 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/coverage.footer.html +3 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/coverage.header.html +37 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/coverage.html +3617 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/index.html +36 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/reflect.js +403 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/run.js +66 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/test/test.js +16659 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/tools/generate-unicode-regex.py +164 -0
- data/node_modules/browserify/node_modules/syntax-error/node_modules/esprima/tools/update-coverage.sh +28 -0
- data/node_modules/browserify/node_modules/syntax-error/package.json +49 -0
- data/node_modules/browserify/node_modules/syntax-error/readme.markdown +87 -0
- data/node_modules/browserify/node_modules/syntax-error/test/check.js +17 -0
- data/node_modules/browserify/node_modules/syntax-error/test/sources/check.js +9 -0
- data/node_modules/browserify/node_modules/vm-browserify/README.markdown +103 -0
- data/node_modules/browserify/node_modules/vm-browserify/example/run/bundle.js +473 -0
- data/node_modules/browserify/node_modules/vm-browserify/example/run/entry.js +6 -0
- data/node_modules/browserify/node_modules/vm-browserify/example/run/index.html +9 -0
- data/node_modules/browserify/node_modules/vm-browserify/example/run/server.js +6 -0
- data/node_modules/browserify/node_modules/vm-browserify/index.js +85 -0
- data/node_modules/browserify/node_modules/vm-browserify/package.json +43 -0
- data/node_modules/browserify/node_modules/vm-browserify/testling/run.js +22 -0
- data/node_modules/browserify/node_modules/vm-browserify/testling/test.sh +11 -0
- data/node_modules/browserify/package.json +78 -0
- data/node_modules/browserify/test/alias.js +58 -0
- data/node_modules/browserify/test/backbone.js +21 -0
- data/node_modules/browserify/test/bin.js +39 -0
- data/node_modules/browserify/test/buffer.js +99 -0
- data/node_modules/browserify/test/bundle.js +32 -0
- data/node_modules/browserify/test/cache.js +28 -0
- data/node_modules/browserify/test/coffee.js +39 -0
- data/node_modules/browserify/test/coffee/bar.js +1 -0
- data/node_modules/browserify/test/coffee/baz.coffee +1 -0
- data/node_modules/browserify/test/coffee/entry.coffee +1 -0
- data/node_modules/browserify/test/coffee/foo.coffee +1 -0
- data/node_modules/browserify/test/coffee/index.coffee +5 -0
- data/node_modules/browserify/test/coffee/nested/nested.coffee +2 -0
- data/node_modules/browserify/test/comment.js +17 -0
- data/node_modules/browserify/test/comment/main.js +2 -0
- data/node_modules/browserify/test/crypto.js +37 -0
- data/node_modules/browserify/test/dnode.js +27 -0
- data/node_modules/browserify/test/dollar.js +19 -0
- data/node_modules/browserify/test/dollar/dollar/index.js +7 -0
- data/node_modules/browserify/test/entry.js +36 -0
- data/node_modules/browserify/test/entry/main.js +1 -0
- data/node_modules/browserify/test/entry/one.js +1 -0
- data/node_modules/browserify/test/entry/two.js +1 -0
- data/node_modules/browserify/test/error_code.js +24 -0
- data/node_modules/browserify/test/error_code/src.js +2 -0
- data/node_modules/browserify/test/export.js +52 -0
- data/node_modules/browserify/test/export/entry.js +1 -0
- data/node_modules/browserify/test/field.js +64 -0
- data/node_modules/browserify/test/field/miss.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-miss/browser.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-miss/main.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-miss/package.json +4 -0
- data/node_modules/browserify/test/field/node_modules/z-object/browser.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-object/main.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-object/package.json +6 -0
- data/node_modules/browserify/test/field/node_modules/z-string/browser.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-string/main.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-string/package.json +4 -0
- data/node_modules/browserify/test/field/node_modules/z-sub/browser/a.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-sub/browser/b.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-sub/main.js +1 -0
- data/node_modules/browserify/test/field/node_modules/z-sub/package.json +4 -0
- data/node_modules/browserify/test/field/object.js +1 -0
- data/node_modules/browserify/test/field/string.js +1 -0
- data/node_modules/browserify/test/field/sub.js +1 -0
- data/node_modules/browserify/test/global.js +19 -0
- data/node_modules/browserify/test/global/main.js +2 -0
- data/node_modules/browserify/test/jade.js +35 -0
- data/node_modules/browserify/test/json.js +17 -0
- data/node_modules/browserify/test/json/beep.json +4 -0
- data/node_modules/browserify/test/json/main.js +1 -0
- data/node_modules/browserify/test/maxlisteners.js +8 -0
- data/node_modules/browserify/test/module.js +22 -0
- data/node_modules/browserify/test/multi_entry.js +20 -0
- data/node_modules/browserify/test/multi_entry/a.js +2 -0
- data/node_modules/browserify/test/multi_entry/b.js +2 -0
- data/node_modules/browserify/test/multi_entry/c.js +3 -0
- data/node_modules/browserify/test/multi_ignore.js +23 -0
- data/node_modules/browserify/test/node_modules/beep/index.js +1 -0
- data/node_modules/browserify/test/require_cache.js +18 -0
- data/node_modules/browserify/test/retarget.js +27 -0
- data/node_modules/browserify/test/seq.js +47 -0
- data/node_modules/browserify/test/subdep.js +26 -0
- data/node_modules/browserify/test/subdep/index.js +1 -0
- data/node_modules/browserify/test/subdep/package.json +6 -0
- data/node_modules/browserify/test/util.js +48 -0
- data/node_modules/browserify/test/watch.js +91 -0
- data/node_modules/browserify/test/watch/a.js +1 -0
- data/node_modules/browserify/test/wrap.js +43 -0
- data/node_modules/browserify/test/wrap/a.js +2 -0
- data/node_modules/browserify/test/wrap/c.js +1 -0
- data/node_modules/browserify/test/wrap/node_modules/b/main.js +1 -0
- data/node_modules/browserify/test/wrap/node_modules/b/package.json +3 -0
- data/node_modules/browserify/test/wrap/node_modules/skipmetoo/index.js +1 -0
- data/node_modules/browserify/test/wrap/skipme.js +1 -0
- data/node_modules/browserify/test/wrap/x.js +0 -0
- data/node_modules/browserify/testling/README.markdown +29 -0
- data/node_modules/browserify/testling/test.sh +37 -0
- data/node_modules/browserify/testling/tick.js +9 -0
- data/node_modules/browserify/testling/timers.js +50 -0
- data/node_modules/browserify/testling/util.js +24 -0
- data/node_modules/browserify/v2.markdown +41 -0
- data/node_modules/browserify/wrappers/alias.js +1 -0
- data/node_modules/browserify/wrappers/body.js +2 -0
- data/node_modules/browserify/wrappers/body_debug.js +2 -0
- data/node_modules/browserify/wrappers/entry.js +3 -0
- data/node_modules/browserify/wrappers/entry_debug.js +3 -0
- data/node_modules/browserify/wrappers/package.js +3 -0
- data/node_modules/browserify/wrappers/prelude.js +196 -0
- data/node_modules/coffee-script/.npmignore +11 -0
- data/node_modules/coffee-script/CNAME +1 -0
- data/node_modules/coffee-script/CONTRIBUTING.md +9 -0
- data/node_modules/coffee-script/LICENSE +22 -0
- data/node_modules/coffee-script/README +51 -0
- data/node_modules/coffee-script/Rakefile +78 -0
- data/node_modules/coffee-script/bin/cake +7 -0
- data/node_modules/coffee-script/bin/coffee +7 -0
- data/node_modules/coffee-script/extras/jsl.conf +44 -0
- data/node_modules/coffee-script/lib/coffee-script/browser.js +92 -0
- data/node_modules/coffee-script/lib/coffee-script/cake.js +113 -0
- data/node_modules/coffee-script/lib/coffee-script/coffee-script.js +171 -0
- data/node_modules/coffee-script/lib/coffee-script/command.js +502 -0
- data/node_modules/coffee-script/lib/coffee-script/grammar.js +606 -0
- data/node_modules/coffee-script/lib/coffee-script/helpers.js +88 -0
- data/node_modules/coffee-script/lib/coffee-script/index.js +11 -0
- data/node_modules/coffee-script/lib/coffee-script/lexer.js +788 -0
- data/node_modules/coffee-script/lib/coffee-script/nodes.js +2971 -0
- data/node_modules/coffee-script/lib/coffee-script/optparse.js +138 -0
- data/node_modules/coffee-script/lib/coffee-script/parser.js +683 -0
- data/node_modules/coffee-script/lib/coffee-script/repl.js +276 -0
- data/node_modules/coffee-script/lib/coffee-script/rewriter.js +349 -0
- data/node_modules/coffee-script/lib/coffee-script/scope.js +146 -0
- data/node_modules/coffee-script/package.json +50 -0
- data/node_modules/jade-runtime/.npmignore +15 -0
- data/node_modules/jade-runtime/README.md +8 -0
- data/node_modules/jade-runtime/globals.js +32 -0
- data/node_modules/jade-runtime/index.js +2 -0
- data/node_modules/jade-runtime/jade-runtime.js +181 -0
- data/node_modules/jade-runtime/package.json +18 -0
- data/node_modules/jade/.npmignore +14 -0
- data/node_modules/jade/LICENSE +22 -0
- data/node_modules/jade/Readme.md +1299 -0
- data/node_modules/jade/bin/jade +168 -0
- data/node_modules/jade/index.js +4 -0
- data/node_modules/jade/jade.js +3586 -0
- data/node_modules/jade/jade.md +510 -0
- data/node_modules/jade/jade.min.js +2 -0
- data/node_modules/jade/lib/compiler.js +654 -0
- data/node_modules/jade/lib/doctypes.js +18 -0
- data/node_modules/jade/lib/filters.js +97 -0
- data/node_modules/jade/lib/inline-tags.js +28 -0
- data/node_modules/jade/lib/jade.js +253 -0
- data/node_modules/jade/lib/lexer.js +774 -0
- data/node_modules/jade/lib/nodes/attrs.js +77 -0
- data/node_modules/jade/lib/nodes/block-comment.js +33 -0
- data/node_modules/jade/lib/nodes/block.js +122 -0
- data/node_modules/jade/lib/nodes/case.js +43 -0
- data/node_modules/jade/lib/nodes/code.js +35 -0
- data/node_modules/jade/lib/nodes/comment.js +32 -0
- data/node_modules/jade/lib/nodes/doctype.js +29 -0
- data/node_modules/jade/lib/nodes/each.js +35 -0
- data/node_modules/jade/lib/nodes/filter.js +35 -0
- data/node_modules/jade/lib/nodes/index.js +20 -0
- data/node_modules/jade/lib/nodes/literal.js +32 -0
- data/node_modules/jade/lib/nodes/mixin.js +36 -0
- data/node_modules/jade/lib/nodes/node.js +25 -0
- data/node_modules/jade/lib/nodes/tag.js +95 -0
- data/node_modules/jade/lib/nodes/text.js +36 -0
- data/node_modules/jade/lib/parser.js +714 -0
- data/node_modules/jade/lib/runtime.js +174 -0
- data/node_modules/jade/lib/self-closing.js +19 -0
- data/node_modules/jade/lib/utils.js +49 -0
- data/node_modules/jade/node_modules/commander/.npmignore +4 -0
- data/node_modules/jade/node_modules/commander/.travis.yml +4 -0
- data/node_modules/jade/node_modules/commander/History.md +107 -0
- data/node_modules/jade/node_modules/commander/Makefile +7 -0
- data/node_modules/jade/node_modules/commander/Readme.md +262 -0
- data/node_modules/jade/node_modules/commander/index.js +2 -0
- data/node_modules/jade/node_modules/commander/lib/commander.js +1026 -0
- data/node_modules/jade/node_modules/commander/package.json +39 -0
- data/node_modules/jade/node_modules/mkdirp/.npmignore +2 -0
- data/node_modules/jade/node_modules/mkdirp/.travis.yml +4 -0
- data/node_modules/jade/node_modules/mkdirp/LICENSE +21 -0
- data/node_modules/jade/node_modules/mkdirp/README.markdown +61 -0
- data/node_modules/jade/node_modules/mkdirp/examples/pow.js +6 -0
- data/node_modules/jade/node_modules/mkdirp/index.js +82 -0
- data/node_modules/jade/node_modules/mkdirp/package.json +37 -0
- data/node_modules/jade/node_modules/mkdirp/test/chmod.js +38 -0
- data/node_modules/jade/node_modules/mkdirp/test/clobber.js +37 -0
- data/node_modules/jade/node_modules/mkdirp/test/mkdirp.js +28 -0
- data/node_modules/jade/node_modules/mkdirp/test/perm.js +32 -0
- data/node_modules/jade/node_modules/mkdirp/test/perm_sync.js +39 -0
- data/node_modules/jade/node_modules/mkdirp/test/race.js +41 -0
- data/node_modules/jade/node_modules/mkdirp/test/rel.js +32 -0
- data/node_modules/jade/node_modules/mkdirp/test/return.js +25 -0
- data/node_modules/jade/node_modules/mkdirp/test/return_sync.js +24 -0
- data/node_modules/jade/node_modules/mkdirp/test/root.js +18 -0
- data/node_modules/jade/node_modules/mkdirp/test/sync.js +32 -0
- data/node_modules/jade/node_modules/mkdirp/test/umask.js +28 -0
- data/node_modules/jade/node_modules/mkdirp/test/umask_sync.js +32 -0
- data/node_modules/jade/package.json +53 -0
- data/node_modules/jade/runtime.js +179 -0
- data/node_modules/jade/runtime.min.js +1 -0
- data/node_modules/jade/test.jade +7 -0
- data/node_modules/jade/testing/head.jade +5 -0
- data/node_modules/jade/testing/index.jade +1 -0
- data/node_modules/jade/testing/index.js +14 -0
- data/node_modules/jade/testing/layout.jade +10 -0
- data/node_modules/jade/testing/user.jade +7 -0
- data/node_modules/jade/testing/user.js +27 -0
- data/node_modules/optimist/.travis.yml +4 -0
- data/node_modules/optimist/LICENSE +21 -0
- data/node_modules/optimist/README.markdown +487 -0
- data/node_modules/optimist/example/bool.js +10 -0
- data/node_modules/optimist/example/boolean_double.js +7 -0
- data/node_modules/optimist/example/boolean_single.js +7 -0
- data/node_modules/optimist/example/default_hash.js +8 -0
- data/node_modules/optimist/example/default_singles.js +7 -0
- data/node_modules/optimist/example/divide.js +8 -0
- data/node_modules/optimist/example/line_count.js +20 -0
- data/node_modules/optimist/example/line_count_options.js +29 -0
- data/node_modules/optimist/example/line_count_wrap.js +29 -0
- data/node_modules/optimist/example/nonopt.js +4 -0
- data/node_modules/optimist/example/reflect.js +2 -0
- data/node_modules/optimist/example/short.js +3 -0
- data/node_modules/optimist/example/string.js +11 -0
- data/node_modules/optimist/example/usage-options.js +19 -0
- data/node_modules/optimist/example/xup.js +10 -0
- data/node_modules/optimist/index.js +475 -0
- data/node_modules/optimist/node_modules/wordwrap/.npmignore +1 -0
- data/node_modules/optimist/node_modules/wordwrap/README.markdown +70 -0
- data/node_modules/optimist/node_modules/wordwrap/example/center.js +10 -0
- data/node_modules/optimist/node_modules/wordwrap/example/meat.js +3 -0
- data/node_modules/optimist/node_modules/wordwrap/index.js +76 -0
- data/node_modules/optimist/node_modules/wordwrap/package.json +45 -0
- data/node_modules/optimist/node_modules/wordwrap/test/break.js +30 -0
- data/node_modules/optimist/node_modules/wordwrap/test/idleness.txt +63 -0
- data/node_modules/optimist/node_modules/wordwrap/test/wrap.js +31 -0
- data/node_modules/optimist/package.json +55 -0
- data/node_modules/optimist/test/_.js +71 -0
- data/node_modules/optimist/test/_/argv.js +2 -0
- data/node_modules/optimist/test/_/bin.js +3 -0
- data/node_modules/optimist/test/parse.js +420 -0
- data/node_modules/optimist/test/usage.js +292 -0
- data/snowball.gemspec +1 -2
- metadata +601 -21
- data/extconf.rb +0 -9
@@ -0,0 +1,18 @@
|
|
1
|
+
|
2
|
+
/*!
|
3
|
+
* Jade - doctypes
|
4
|
+
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
|
5
|
+
* MIT Licensed
|
6
|
+
*/
|
7
|
+
|
8
|
+
module.exports = {
|
9
|
+
'5': '<!DOCTYPE html>'
|
10
|
+
, 'default': '<!DOCTYPE html>'
|
11
|
+
, 'xml': '<?xml version="1.0" encoding="utf-8" ?>'
|
12
|
+
, 'transitional': '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'
|
13
|
+
, 'strict': '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'
|
14
|
+
, 'frameset': '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">'
|
15
|
+
, '1.1': '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">'
|
16
|
+
, 'basic': '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML Basic 1.1//EN" "http://www.w3.org/TR/xhtml-basic/xhtml-basic11.dtd">'
|
17
|
+
, 'mobile': '<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile12.dtd">'
|
18
|
+
};
|
@@ -0,0 +1,97 @@
|
|
1
|
+
|
2
|
+
/*!
|
3
|
+
* Jade - filters
|
4
|
+
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
|
5
|
+
* MIT Licensed
|
6
|
+
*/
|
7
|
+
|
8
|
+
module.exports = {
|
9
|
+
|
10
|
+
/**
|
11
|
+
* Wrap text with CDATA block.
|
12
|
+
*/
|
13
|
+
|
14
|
+
cdata: function(str){
|
15
|
+
return '<![CDATA[\\n' + str + '\\n]]>';
|
16
|
+
},
|
17
|
+
|
18
|
+
/**
|
19
|
+
* Transform sass to css, wrapped in style tags.
|
20
|
+
*/
|
21
|
+
|
22
|
+
sass: function(str){
|
23
|
+
str = str.replace(/\\n/g, '\n');
|
24
|
+
var sass = require('sass').render(str).replace(/\n/g, '\\n');
|
25
|
+
return '<style type="text/css">' + sass + '</style>';
|
26
|
+
},
|
27
|
+
|
28
|
+
/**
|
29
|
+
* Transform stylus to css, wrapped in style tags.
|
30
|
+
*/
|
31
|
+
|
32
|
+
stylus: function(str, options){
|
33
|
+
var ret;
|
34
|
+
str = str.replace(/\\n/g, '\n');
|
35
|
+
var stylus = require('stylus');
|
36
|
+
stylus(str, options).render(function(err, css){
|
37
|
+
if (err) throw err;
|
38
|
+
ret = css.replace(/\n/g, '\\n');
|
39
|
+
});
|
40
|
+
return '<style type="text/css">' + ret + '</style>';
|
41
|
+
},
|
42
|
+
|
43
|
+
/**
|
44
|
+
* Transform less to css, wrapped in style tags.
|
45
|
+
*/
|
46
|
+
|
47
|
+
less: function(str){
|
48
|
+
var ret;
|
49
|
+
str = str.replace(/\\n/g, '\n');
|
50
|
+
require('less').render(str, function(err, css){
|
51
|
+
if (err) throw err;
|
52
|
+
ret = '<style type="text/css">' + css.replace(/\n/g, '\\n') + '</style>';
|
53
|
+
});
|
54
|
+
return ret;
|
55
|
+
},
|
56
|
+
|
57
|
+
/**
|
58
|
+
* Transform markdown to html.
|
59
|
+
*/
|
60
|
+
|
61
|
+
markdown: function(str){
|
62
|
+
var md;
|
63
|
+
|
64
|
+
// support markdown / discount
|
65
|
+
try {
|
66
|
+
md = require('markdown');
|
67
|
+
} catch (err){
|
68
|
+
try {
|
69
|
+
md = require('discount');
|
70
|
+
} catch (err) {
|
71
|
+
try {
|
72
|
+
md = require('markdown-js');
|
73
|
+
} catch (err) {
|
74
|
+
try {
|
75
|
+
md = require('marked');
|
76
|
+
} catch (err) {
|
77
|
+
throw new
|
78
|
+
Error('Cannot find markdown library, install markdown, discount, or marked.');
|
79
|
+
}
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
83
|
+
|
84
|
+
str = str.replace(/\\n/g, '\n');
|
85
|
+
return md.parse(str).replace(/\n/g, '\\n').replace(/'/g,''');
|
86
|
+
},
|
87
|
+
|
88
|
+
/**
|
89
|
+
* Transform coffeescript to javascript.
|
90
|
+
*/
|
91
|
+
|
92
|
+
coffeescript: function(str){
|
93
|
+
str = str.replace(/\\n/g, '\n');
|
94
|
+
var js = require('coffee-script').compile(str).replace(/\\/g, '\\\\').replace(/\n/g, '\\n');
|
95
|
+
return '<script type="text/javascript">\\n' + js + '</script>';
|
96
|
+
}
|
97
|
+
};
|
@@ -0,0 +1,28 @@
|
|
1
|
+
|
2
|
+
/*!
|
3
|
+
* Jade - inline tags
|
4
|
+
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
|
5
|
+
* MIT Licensed
|
6
|
+
*/
|
7
|
+
|
8
|
+
module.exports = [
|
9
|
+
'a'
|
10
|
+
, 'abbr'
|
11
|
+
, 'acronym'
|
12
|
+
, 'b'
|
13
|
+
, 'br'
|
14
|
+
, 'code'
|
15
|
+
, 'em'
|
16
|
+
, 'font'
|
17
|
+
, 'i'
|
18
|
+
, 'img'
|
19
|
+
, 'ins'
|
20
|
+
, 'kbd'
|
21
|
+
, 'map'
|
22
|
+
, 'samp'
|
23
|
+
, 'small'
|
24
|
+
, 'span'
|
25
|
+
, 'strong'
|
26
|
+
, 'sub'
|
27
|
+
, 'sup'
|
28
|
+
];
|
@@ -0,0 +1,253 @@
|
|
1
|
+
/*!
|
2
|
+
* Jade
|
3
|
+
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
|
4
|
+
* MIT Licensed
|
5
|
+
*/
|
6
|
+
|
7
|
+
/**
|
8
|
+
* Module dependencies.
|
9
|
+
*/
|
10
|
+
|
11
|
+
var Parser = require('./parser')
|
12
|
+
, Lexer = require('./lexer')
|
13
|
+
, Compiler = require('./compiler')
|
14
|
+
, runtime = require('./runtime')
|
15
|
+
// if node
|
16
|
+
, fs = require('fs');
|
17
|
+
// end
|
18
|
+
|
19
|
+
/**
|
20
|
+
* Library version.
|
21
|
+
*/
|
22
|
+
|
23
|
+
exports.version = '0.27.5';
|
24
|
+
|
25
|
+
/**
|
26
|
+
* Expose self closing tags.
|
27
|
+
*/
|
28
|
+
|
29
|
+
exports.selfClosing = require('./self-closing');
|
30
|
+
|
31
|
+
/**
|
32
|
+
* Default supported doctypes.
|
33
|
+
*/
|
34
|
+
|
35
|
+
exports.doctypes = require('./doctypes');
|
36
|
+
|
37
|
+
/**
|
38
|
+
* Text filters.
|
39
|
+
*/
|
40
|
+
|
41
|
+
exports.filters = require('./filters');
|
42
|
+
|
43
|
+
/**
|
44
|
+
* Utilities.
|
45
|
+
*/
|
46
|
+
|
47
|
+
exports.utils = require('./utils');
|
48
|
+
|
49
|
+
/**
|
50
|
+
* Expose `Compiler`.
|
51
|
+
*/
|
52
|
+
|
53
|
+
exports.Compiler = Compiler;
|
54
|
+
|
55
|
+
/**
|
56
|
+
* Expose `Parser`.
|
57
|
+
*/
|
58
|
+
|
59
|
+
exports.Parser = Parser;
|
60
|
+
|
61
|
+
/**
|
62
|
+
* Expose `Lexer`.
|
63
|
+
*/
|
64
|
+
|
65
|
+
exports.Lexer = Lexer;
|
66
|
+
|
67
|
+
/**
|
68
|
+
* Nodes.
|
69
|
+
*/
|
70
|
+
|
71
|
+
exports.nodes = require('./nodes');
|
72
|
+
|
73
|
+
/**
|
74
|
+
* Jade runtime helpers.
|
75
|
+
*/
|
76
|
+
|
77
|
+
exports.runtime = runtime;
|
78
|
+
|
79
|
+
/**
|
80
|
+
* Template function cache.
|
81
|
+
*/
|
82
|
+
|
83
|
+
exports.cache = {};
|
84
|
+
|
85
|
+
/**
|
86
|
+
* Parse the given `str` of jade and return a function body.
|
87
|
+
*
|
88
|
+
* @param {String} str
|
89
|
+
* @param {Object} options
|
90
|
+
* @return {String}
|
91
|
+
* @api private
|
92
|
+
*/
|
93
|
+
|
94
|
+
function parse(str, options){
|
95
|
+
try {
|
96
|
+
// Parse
|
97
|
+
var parser = new Parser(str, options.filename, options);
|
98
|
+
|
99
|
+
// Compile
|
100
|
+
var compiler = new (options.compiler || Compiler)(parser.parse(), options)
|
101
|
+
, js = compiler.compile();
|
102
|
+
|
103
|
+
// Debug compiler
|
104
|
+
if (options.debug) {
|
105
|
+
console.error('\nCompiled Function:\n\n\033[90m%s\033[0m', js.replace(/^/gm, ' '));
|
106
|
+
}
|
107
|
+
|
108
|
+
return ''
|
109
|
+
+ 'var buf = [];\n'
|
110
|
+
+ (options.self
|
111
|
+
? 'var self = locals || {};\n' + js
|
112
|
+
: 'with (locals || {}) {\n' + js + '\n}\n')
|
113
|
+
+ 'return buf.join("");';
|
114
|
+
} catch (err) {
|
115
|
+
parser = parser.context();
|
116
|
+
runtime.rethrow(err, parser.filename, parser.lexer.lineno);
|
117
|
+
}
|
118
|
+
}
|
119
|
+
|
120
|
+
/**
|
121
|
+
* Strip any UTF-8 BOM off of the start of `str`, if it exists.
|
122
|
+
*
|
123
|
+
* @param {String} str
|
124
|
+
* @return {String}
|
125
|
+
* @api private
|
126
|
+
*/
|
127
|
+
|
128
|
+
function stripBOM(str){
|
129
|
+
return 0xFEFF == str.charCodeAt(0)
|
130
|
+
? str.substring(1)
|
131
|
+
: str;
|
132
|
+
}
|
133
|
+
|
134
|
+
/**
|
135
|
+
* Compile a `Function` representation of the given jade `str`.
|
136
|
+
*
|
137
|
+
* Options:
|
138
|
+
*
|
139
|
+
* - `compileDebug` when `false` debugging code is stripped from the compiled template
|
140
|
+
* - `client` when `true` the helper functions `escape()` etc will reference `jade.escape()`
|
141
|
+
* for use with the Jade client-side runtime.js
|
142
|
+
*
|
143
|
+
* @param {String} str
|
144
|
+
* @param {Options} options
|
145
|
+
* @return {Function}
|
146
|
+
* @api public
|
147
|
+
*/
|
148
|
+
|
149
|
+
exports.compile = function(str, options){
|
150
|
+
var options = options || {}
|
151
|
+
, client = options.client
|
152
|
+
, filename = options.filename
|
153
|
+
? JSON.stringify(options.filename)
|
154
|
+
: 'undefined'
|
155
|
+
, fn;
|
156
|
+
|
157
|
+
str = stripBOM(String(str));
|
158
|
+
|
159
|
+
if (options.compileDebug !== false) {
|
160
|
+
fn = [
|
161
|
+
'var __jade = [{ lineno: 1, filename: ' + filename + ' }];'
|
162
|
+
, 'try {'
|
163
|
+
, parse(str, options)
|
164
|
+
, '} catch (err) {'
|
165
|
+
, ' rethrow(err, __jade[0].filename, __jade[0].lineno);'
|
166
|
+
, '}'
|
167
|
+
].join('\n');
|
168
|
+
} else {
|
169
|
+
fn = parse(str, options);
|
170
|
+
}
|
171
|
+
|
172
|
+
if (client) {
|
173
|
+
fn = 'attrs = attrs || jade.attrs; escape = escape || jade.escape; rethrow = rethrow || jade.rethrow; merge = merge || jade.merge;\n' + fn;
|
174
|
+
}
|
175
|
+
|
176
|
+
fn = new Function('locals, attrs, escape, rethrow, merge', fn);
|
177
|
+
|
178
|
+
if (client) return fn;
|
179
|
+
|
180
|
+
return function(locals){
|
181
|
+
return fn(locals, runtime.attrs, runtime.escape, runtime.rethrow, runtime.merge);
|
182
|
+
};
|
183
|
+
};
|
184
|
+
|
185
|
+
/**
|
186
|
+
* Render the given `str` of jade and invoke
|
187
|
+
* the callback `fn(err, str)`.
|
188
|
+
*
|
189
|
+
* Options:
|
190
|
+
*
|
191
|
+
* - `cache` enable template caching
|
192
|
+
* - `filename` filename required for `include` / `extends` and caching
|
193
|
+
*
|
194
|
+
* @param {String} str
|
195
|
+
* @param {Object|Function} options or fn
|
196
|
+
* @param {Function} fn
|
197
|
+
* @api public
|
198
|
+
*/
|
199
|
+
|
200
|
+
exports.render = function(str, options, fn){
|
201
|
+
// swap args
|
202
|
+
if ('function' == typeof options) {
|
203
|
+
fn = options, options = {};
|
204
|
+
}
|
205
|
+
|
206
|
+
// cache requires .filename
|
207
|
+
if (options.cache && !options.filename) {
|
208
|
+
return fn(new Error('the "filename" option is required for caching'));
|
209
|
+
}
|
210
|
+
|
211
|
+
try {
|
212
|
+
var path = options.filename;
|
213
|
+
var tmpl = options.cache
|
214
|
+
? exports.cache[path] || (exports.cache[path] = exports.compile(str, options))
|
215
|
+
: exports.compile(str, options);
|
216
|
+
fn(null, tmpl(options));
|
217
|
+
} catch (err) {
|
218
|
+
fn(err);
|
219
|
+
}
|
220
|
+
};
|
221
|
+
|
222
|
+
/**
|
223
|
+
* Render a Jade file at the given `path` and callback `fn(err, str)`.
|
224
|
+
*
|
225
|
+
* @param {String} path
|
226
|
+
* @param {Object|Function} options or callback
|
227
|
+
* @param {Function} fn
|
228
|
+
* @api public
|
229
|
+
*/
|
230
|
+
|
231
|
+
exports.renderFile = function(path, options, fn){
|
232
|
+
var key = path + ':string';
|
233
|
+
|
234
|
+
if ('function' == typeof options) {
|
235
|
+
fn = options, options = {};
|
236
|
+
}
|
237
|
+
|
238
|
+
try {
|
239
|
+
options.filename = path;
|
240
|
+
var str = options.cache
|
241
|
+
? exports.cache[key] || (exports.cache[key] = fs.readFileSync(path, 'utf8'))
|
242
|
+
: fs.readFileSync(path, 'utf8');
|
243
|
+
exports.render(str, options, fn);
|
244
|
+
} catch (err) {
|
245
|
+
fn(err);
|
246
|
+
}
|
247
|
+
};
|
248
|
+
|
249
|
+
/**
|
250
|
+
* Express support.
|
251
|
+
*/
|
252
|
+
|
253
|
+
exports.__express = exports.renderFile;
|
@@ -0,0 +1,774 @@
|
|
1
|
+
/*!
|
2
|
+
* Jade - Lexer
|
3
|
+
* Copyright(c) 2010 TJ Holowaychuk <tj@vision-media.ca>
|
4
|
+
* MIT Licensed
|
5
|
+
*/
|
6
|
+
|
7
|
+
var utils = require('./utils');
|
8
|
+
|
9
|
+
/**
|
10
|
+
* Initialize `Lexer` with the given `str`.
|
11
|
+
*
|
12
|
+
* Options:
|
13
|
+
*
|
14
|
+
* - `colons` allow colons for attr delimiters
|
15
|
+
*
|
16
|
+
* @param {String} str
|
17
|
+
* @param {Object} options
|
18
|
+
* @api private
|
19
|
+
*/
|
20
|
+
|
21
|
+
var Lexer = module.exports = function Lexer(str, options) {
|
22
|
+
options = options || {};
|
23
|
+
this.input = str.replace(/\r\n|\r/g, '\n');
|
24
|
+
this.colons = options.colons;
|
25
|
+
this.deferredTokens = [];
|
26
|
+
this.lastIndents = 0;
|
27
|
+
this.lineno = 1;
|
28
|
+
this.stash = [];
|
29
|
+
this.indentStack = [];
|
30
|
+
this.indentRe = null;
|
31
|
+
this.pipeless = false;
|
32
|
+
};
|
33
|
+
|
34
|
+
/**
|
35
|
+
* Lexer prototype.
|
36
|
+
*/
|
37
|
+
|
38
|
+
Lexer.prototype = {
|
39
|
+
|
40
|
+
/**
|
41
|
+
* Construct a token with the given `type` and `val`.
|
42
|
+
*
|
43
|
+
* @param {String} type
|
44
|
+
* @param {String} val
|
45
|
+
* @return {Object}
|
46
|
+
* @api private
|
47
|
+
*/
|
48
|
+
|
49
|
+
tok: function(type, val){
|
50
|
+
return {
|
51
|
+
type: type
|
52
|
+
, line: this.lineno
|
53
|
+
, val: val
|
54
|
+
}
|
55
|
+
},
|
56
|
+
|
57
|
+
/**
|
58
|
+
* Consume the given `len` of input.
|
59
|
+
*
|
60
|
+
* @param {Number} len
|
61
|
+
* @api private
|
62
|
+
*/
|
63
|
+
|
64
|
+
consume: function(len){
|
65
|
+
this.input = this.input.substr(len);
|
66
|
+
},
|
67
|
+
|
68
|
+
/**
|
69
|
+
* Scan for `type` with the given `regexp`.
|
70
|
+
*
|
71
|
+
* @param {String} type
|
72
|
+
* @param {RegExp} regexp
|
73
|
+
* @return {Object}
|
74
|
+
* @api private
|
75
|
+
*/
|
76
|
+
|
77
|
+
scan: function(regexp, type){
|
78
|
+
var captures;
|
79
|
+
if (captures = regexp.exec(this.input)) {
|
80
|
+
this.consume(captures[0].length);
|
81
|
+
return this.tok(type, captures[1]);
|
82
|
+
}
|
83
|
+
},
|
84
|
+
|
85
|
+
/**
|
86
|
+
* Defer the given `tok`.
|
87
|
+
*
|
88
|
+
* @param {Object} tok
|
89
|
+
* @api private
|
90
|
+
*/
|
91
|
+
|
92
|
+
defer: function(tok){
|
93
|
+
this.deferredTokens.push(tok);
|
94
|
+
},
|
95
|
+
|
96
|
+
/**
|
97
|
+
* Lookahead `n` tokens.
|
98
|
+
*
|
99
|
+
* @param {Number} n
|
100
|
+
* @return {Object}
|
101
|
+
* @api private
|
102
|
+
*/
|
103
|
+
|
104
|
+
lookahead: function(n){
|
105
|
+
var fetch = n - this.stash.length;
|
106
|
+
while (fetch-- > 0) this.stash.push(this.next());
|
107
|
+
return this.stash[--n];
|
108
|
+
},
|
109
|
+
|
110
|
+
/**
|
111
|
+
* Return the indexOf `start` / `end` delimiters.
|
112
|
+
*
|
113
|
+
* @param {String} start
|
114
|
+
* @param {String} end
|
115
|
+
* @return {Number}
|
116
|
+
* @api private
|
117
|
+
*/
|
118
|
+
|
119
|
+
indexOfDelimiters: function(start, end){
|
120
|
+
var str = this.input
|
121
|
+
, nstart = 0
|
122
|
+
, nend = 0
|
123
|
+
, pos = 0;
|
124
|
+
for (var i = 0, len = str.length; i < len; ++i) {
|
125
|
+
if (start == str.charAt(i)) {
|
126
|
+
++nstart;
|
127
|
+
} else if (end == str.charAt(i)) {
|
128
|
+
if (++nend == nstart) {
|
129
|
+
pos = i;
|
130
|
+
break;
|
131
|
+
}
|
132
|
+
}
|
133
|
+
}
|
134
|
+
return pos;
|
135
|
+
},
|
136
|
+
|
137
|
+
/**
|
138
|
+
* Stashed token.
|
139
|
+
*/
|
140
|
+
|
141
|
+
stashed: function() {
|
142
|
+
return this.stash.length
|
143
|
+
&& this.stash.shift();
|
144
|
+
},
|
145
|
+
|
146
|
+
/**
|
147
|
+
* Deferred token.
|
148
|
+
*/
|
149
|
+
|
150
|
+
deferred: function() {
|
151
|
+
return this.deferredTokens.length
|
152
|
+
&& this.deferredTokens.shift();
|
153
|
+
},
|
154
|
+
|
155
|
+
/**
|
156
|
+
* end-of-source.
|
157
|
+
*/
|
158
|
+
|
159
|
+
eos: function() {
|
160
|
+
if (this.input.length) return;
|
161
|
+
if (this.indentStack.length) {
|
162
|
+
this.indentStack.shift();
|
163
|
+
return this.tok('outdent');
|
164
|
+
} else {
|
165
|
+
return this.tok('eos');
|
166
|
+
}
|
167
|
+
},
|
168
|
+
|
169
|
+
/**
|
170
|
+
* Blank line.
|
171
|
+
*/
|
172
|
+
|
173
|
+
blank: function() {
|
174
|
+
var captures;
|
175
|
+
if (captures = /^\n *\n/.exec(this.input)) {
|
176
|
+
this.consume(captures[0].length - 1);
|
177
|
+
if (this.pipeless) return this.tok('text', '');
|
178
|
+
return this.next();
|
179
|
+
}
|
180
|
+
},
|
181
|
+
|
182
|
+
/**
|
183
|
+
* Comment.
|
184
|
+
*/
|
185
|
+
|
186
|
+
comment: function() {
|
187
|
+
var captures;
|
188
|
+
if (captures = /^ *\/\/(-)?([^\n]*)/.exec(this.input)) {
|
189
|
+
this.consume(captures[0].length);
|
190
|
+
var tok = this.tok('comment', captures[2]);
|
191
|
+
tok.buffer = '-' != captures[1];
|
192
|
+
return tok;
|
193
|
+
}
|
194
|
+
},
|
195
|
+
|
196
|
+
/**
|
197
|
+
* Interpolated tag.
|
198
|
+
*/
|
199
|
+
|
200
|
+
interpolation: function() {
|
201
|
+
var captures;
|
202
|
+
if (captures = /^#\{(.*?)\}/.exec(this.input)) {
|
203
|
+
this.consume(captures[0].length);
|
204
|
+
return this.tok('interpolation', captures[1]);
|
205
|
+
}
|
206
|
+
},
|
207
|
+
|
208
|
+
/**
|
209
|
+
* Tag.
|
210
|
+
*/
|
211
|
+
|
212
|
+
tag: function() {
|
213
|
+
var captures;
|
214
|
+
if (captures = /^(\w[-:\w]*)(\/?)/.exec(this.input)) {
|
215
|
+
this.consume(captures[0].length);
|
216
|
+
var tok, name = captures[1];
|
217
|
+
if (':' == name[name.length - 1]) {
|
218
|
+
name = name.slice(0, -1);
|
219
|
+
tok = this.tok('tag', name);
|
220
|
+
this.defer(this.tok(':'));
|
221
|
+
while (' ' == this.input[0]) this.input = this.input.substr(1);
|
222
|
+
} else {
|
223
|
+
tok = this.tok('tag', name);
|
224
|
+
}
|
225
|
+
tok.selfClosing = !! captures[2];
|
226
|
+
return tok;
|
227
|
+
}
|
228
|
+
},
|
229
|
+
|
230
|
+
/**
|
231
|
+
* Filter.
|
232
|
+
*/
|
233
|
+
|
234
|
+
filter: function() {
|
235
|
+
return this.scan(/^:(\w+)/, 'filter');
|
236
|
+
},
|
237
|
+
|
238
|
+
/**
|
239
|
+
* Doctype.
|
240
|
+
*/
|
241
|
+
|
242
|
+
doctype: function() {
|
243
|
+
return this.scan(/^(?:!!!|doctype) *([^\n]+)?/, 'doctype');
|
244
|
+
},
|
245
|
+
|
246
|
+
/**
|
247
|
+
* Id.
|
248
|
+
*/
|
249
|
+
|
250
|
+
id: function() {
|
251
|
+
return this.scan(/^#([\w-]+)/, 'id');
|
252
|
+
},
|
253
|
+
|
254
|
+
/**
|
255
|
+
* Class.
|
256
|
+
*/
|
257
|
+
|
258
|
+
className: function() {
|
259
|
+
return this.scan(/^\.([\w-]+)/, 'class');
|
260
|
+
},
|
261
|
+
|
262
|
+
/**
|
263
|
+
* Text.
|
264
|
+
*/
|
265
|
+
|
266
|
+
text: function() {
|
267
|
+
return this.scan(/^(?:\| ?| ?)?([^\n]+)/, 'text');
|
268
|
+
},
|
269
|
+
|
270
|
+
/**
|
271
|
+
* Extends.
|
272
|
+
*/
|
273
|
+
|
274
|
+
"extends": function() {
|
275
|
+
return this.scan(/^extends? +([^\n]+)/, 'extends');
|
276
|
+
},
|
277
|
+
|
278
|
+
/**
|
279
|
+
* Block prepend.
|
280
|
+
*/
|
281
|
+
|
282
|
+
prepend: function() {
|
283
|
+
var captures;
|
284
|
+
if (captures = /^prepend +([^\n]+)/.exec(this.input)) {
|
285
|
+
this.consume(captures[0].length);
|
286
|
+
var mode = 'prepend'
|
287
|
+
, name = captures[1]
|
288
|
+
, tok = this.tok('block', name);
|
289
|
+
tok.mode = mode;
|
290
|
+
return tok;
|
291
|
+
}
|
292
|
+
},
|
293
|
+
|
294
|
+
/**
|
295
|
+
* Block append.
|
296
|
+
*/
|
297
|
+
|
298
|
+
append: function() {
|
299
|
+
var captures;
|
300
|
+
if (captures = /^append +([^\n]+)/.exec(this.input)) {
|
301
|
+
this.consume(captures[0].length);
|
302
|
+
var mode = 'append'
|
303
|
+
, name = captures[1]
|
304
|
+
, tok = this.tok('block', name);
|
305
|
+
tok.mode = mode;
|
306
|
+
return tok;
|
307
|
+
}
|
308
|
+
},
|
309
|
+
|
310
|
+
/**
|
311
|
+
* Block.
|
312
|
+
*/
|
313
|
+
|
314
|
+
block: function() {
|
315
|
+
var captures;
|
316
|
+
if (captures = /^block\b *(?:(prepend|append) +)?([^\n]*)/.exec(this.input)) {
|
317
|
+
this.consume(captures[0].length);
|
318
|
+
var mode = captures[1] || 'replace'
|
319
|
+
, name = captures[2]
|
320
|
+
, tok = this.tok('block', name);
|
321
|
+
|
322
|
+
tok.mode = mode;
|
323
|
+
return tok;
|
324
|
+
}
|
325
|
+
},
|
326
|
+
|
327
|
+
/**
|
328
|
+
* Yield.
|
329
|
+
*/
|
330
|
+
|
331
|
+
yield: function() {
|
332
|
+
return this.scan(/^yield */, 'yield');
|
333
|
+
},
|
334
|
+
|
335
|
+
/**
|
336
|
+
* Include.
|
337
|
+
*/
|
338
|
+
|
339
|
+
include: function() {
|
340
|
+
return this.scan(/^include +([^\n]+)/, 'include');
|
341
|
+
},
|
342
|
+
|
343
|
+
/**
|
344
|
+
* Case.
|
345
|
+
*/
|
346
|
+
|
347
|
+
"case": function() {
|
348
|
+
return this.scan(/^case +([^\n]+)/, 'case');
|
349
|
+
},
|
350
|
+
|
351
|
+
/**
|
352
|
+
* When.
|
353
|
+
*/
|
354
|
+
|
355
|
+
when: function() {
|
356
|
+
return this.scan(/^when +([^:\n]+)/, 'when');
|
357
|
+
},
|
358
|
+
|
359
|
+
/**
|
360
|
+
* Default.
|
361
|
+
*/
|
362
|
+
|
363
|
+
"default": function() {
|
364
|
+
return this.scan(/^default */, 'default');
|
365
|
+
},
|
366
|
+
|
367
|
+
/**
|
368
|
+
* Assignment.
|
369
|
+
*/
|
370
|
+
|
371
|
+
assignment: function() {
|
372
|
+
var captures;
|
373
|
+
if (captures = /^(\w+) += *([^;\n]+)( *;? *)/.exec(this.input)) {
|
374
|
+
this.consume(captures[0].length);
|
375
|
+
var name = captures[1]
|
376
|
+
, val = captures[2];
|
377
|
+
return this.tok('code', 'var ' + name + ' = (' + val + ');');
|
378
|
+
}
|
379
|
+
},
|
380
|
+
|
381
|
+
/**
|
382
|
+
* Call mixin.
|
383
|
+
*/
|
384
|
+
|
385
|
+
call: function(){
|
386
|
+
var captures;
|
387
|
+
if (captures = /^\+([-\w]+)/.exec(this.input)) {
|
388
|
+
this.consume(captures[0].length);
|
389
|
+
var tok = this.tok('call', captures[1]);
|
390
|
+
|
391
|
+
// Check for args (not attributes)
|
392
|
+
if (captures = /^ *\((.*?)\)/.exec(this.input)) {
|
393
|
+
if (!/^ *[-\w]+ *=/.test(captures[1])) {
|
394
|
+
this.consume(captures[0].length);
|
395
|
+
tok.args = captures[1];
|
396
|
+
}
|
397
|
+
}
|
398
|
+
|
399
|
+
return tok;
|
400
|
+
}
|
401
|
+
},
|
402
|
+
|
403
|
+
/**
|
404
|
+
* Mixin.
|
405
|
+
*/
|
406
|
+
|
407
|
+
mixin: function(){
|
408
|
+
var captures;
|
409
|
+
if (captures = /^mixin +([-\w]+)(?: *\((.*)\))?/.exec(this.input)) {
|
410
|
+
this.consume(captures[0].length);
|
411
|
+
var tok = this.tok('mixin', captures[1]);
|
412
|
+
tok.args = captures[2];
|
413
|
+
return tok;
|
414
|
+
}
|
415
|
+
},
|
416
|
+
|
417
|
+
/**
|
418
|
+
* Conditional.
|
419
|
+
*/
|
420
|
+
|
421
|
+
conditional: function() {
|
422
|
+
var captures;
|
423
|
+
if (captures = /^(if|unless|else if|else)\b([^\n]*)/.exec(this.input)) {
|
424
|
+
this.consume(captures[0].length);
|
425
|
+
var type = captures[1]
|
426
|
+
, js = captures[2];
|
427
|
+
|
428
|
+
switch (type) {
|
429
|
+
case 'if': js = 'if (' + js + ')'; break;
|
430
|
+
case 'unless': js = 'if (!(' + js + '))'; break;
|
431
|
+
case 'else if': js = 'else if (' + js + ')'; break;
|
432
|
+
case 'else': js = 'else'; break;
|
433
|
+
}
|
434
|
+
|
435
|
+
return this.tok('code', js);
|
436
|
+
}
|
437
|
+
},
|
438
|
+
|
439
|
+
/**
|
440
|
+
* While.
|
441
|
+
*/
|
442
|
+
|
443
|
+
"while": function() {
|
444
|
+
var captures;
|
445
|
+
if (captures = /^while +([^\n]+)/.exec(this.input)) {
|
446
|
+
this.consume(captures[0].length);
|
447
|
+
return this.tok('code', 'while (' + captures[1] + ')');
|
448
|
+
}
|
449
|
+
},
|
450
|
+
|
451
|
+
/**
|
452
|
+
* Each.
|
453
|
+
*/
|
454
|
+
|
455
|
+
each: function() {
|
456
|
+
var captures;
|
457
|
+
if (captures = /^(?:- *)?(?:each|for) +(\w+)(?: *, *(\w+))? * in *([^\n]+)/.exec(this.input)) {
|
458
|
+
this.consume(captures[0].length);
|
459
|
+
var tok = this.tok('each', captures[1]);
|
460
|
+
tok.key = captures[2] || '$index';
|
461
|
+
tok.code = captures[3];
|
462
|
+
return tok;
|
463
|
+
}
|
464
|
+
},
|
465
|
+
|
466
|
+
/**
|
467
|
+
* Code.
|
468
|
+
*/
|
469
|
+
|
470
|
+
code: function() {
|
471
|
+
var captures;
|
472
|
+
if (captures = /^(!?=|-)([^\n]+)/.exec(this.input)) {
|
473
|
+
this.consume(captures[0].length);
|
474
|
+
var flags = captures[1];
|
475
|
+
captures[1] = captures[2];
|
476
|
+
var tok = this.tok('code', captures[1]);
|
477
|
+
tok.escape = flags.charAt(0) === '=';
|
478
|
+
tok.buffer = flags.charAt(0) === '=' || flags.charAt(1) === '=';
|
479
|
+
return tok;
|
480
|
+
}
|
481
|
+
},
|
482
|
+
|
483
|
+
/**
|
484
|
+
* Attributes.
|
485
|
+
*/
|
486
|
+
|
487
|
+
attrs: function() {
|
488
|
+
if ('(' == this.input.charAt(0)) {
|
489
|
+
var index = this.indexOfDelimiters('(', ')')
|
490
|
+
, str = this.input.substr(1, index-1)
|
491
|
+
, tok = this.tok('attrs')
|
492
|
+
, len = str.length
|
493
|
+
, colons = this.colons
|
494
|
+
, states = ['key']
|
495
|
+
, escapedAttr
|
496
|
+
, key = ''
|
497
|
+
, val = ''
|
498
|
+
, quote
|
499
|
+
, c
|
500
|
+
, p;
|
501
|
+
|
502
|
+
function state(){
|
503
|
+
return states[states.length - 1];
|
504
|
+
}
|
505
|
+
|
506
|
+
function interpolate(attr) {
|
507
|
+
return attr.replace(/(\\)?#\{([^}]+)\}/g, function(_, escape, expr){
|
508
|
+
return escape
|
509
|
+
? _
|
510
|
+
: quote + " + (" + expr + ") + " + quote;
|
511
|
+
});
|
512
|
+
}
|
513
|
+
|
514
|
+
this.consume(index + 1);
|
515
|
+
tok.attrs = {};
|
516
|
+
tok.escaped = {};
|
517
|
+
|
518
|
+
function parse(c) {
|
519
|
+
var real = c;
|
520
|
+
// TODO: remove when people fix ":"
|
521
|
+
if (colons && ':' == c) c = '=';
|
522
|
+
switch (c) {
|
523
|
+
case ',':
|
524
|
+
case '\n':
|
525
|
+
switch (state()) {
|
526
|
+
case 'expr':
|
527
|
+
case 'array':
|
528
|
+
case 'string':
|
529
|
+
case 'object':
|
530
|
+
val += c;
|
531
|
+
break;
|
532
|
+
default:
|
533
|
+
states.push('key');
|
534
|
+
val = val.trim();
|
535
|
+
key = key.trim();
|
536
|
+
if ('' == key) return;
|
537
|
+
key = key.replace(/^['"]|['"]$/g, '').replace('!', '');
|
538
|
+
tok.escaped[key] = escapedAttr;
|
539
|
+
tok.attrs[key] = '' == val
|
540
|
+
? true
|
541
|
+
: interpolate(val);
|
542
|
+
key = val = '';
|
543
|
+
}
|
544
|
+
break;
|
545
|
+
case '=':
|
546
|
+
switch (state()) {
|
547
|
+
case 'key char':
|
548
|
+
key += real;
|
549
|
+
break;
|
550
|
+
case 'val':
|
551
|
+
case 'expr':
|
552
|
+
case 'array':
|
553
|
+
case 'string':
|
554
|
+
case 'object':
|
555
|
+
val += real;
|
556
|
+
break;
|
557
|
+
default:
|
558
|
+
escapedAttr = '!' != p;
|
559
|
+
states.push('val');
|
560
|
+
}
|
561
|
+
break;
|
562
|
+
case '(':
|
563
|
+
if ('val' == state()
|
564
|
+
|| 'expr' == state()) states.push('expr');
|
565
|
+
val += c;
|
566
|
+
break;
|
567
|
+
case ')':
|
568
|
+
if ('expr' == state()
|
569
|
+
|| 'val' == state()) states.pop();
|
570
|
+
val += c;
|
571
|
+
break;
|
572
|
+
case '{':
|
573
|
+
if ('val' == state()) states.push('object');
|
574
|
+
val += c;
|
575
|
+
break;
|
576
|
+
case '}':
|
577
|
+
if ('object' == state()) states.pop();
|
578
|
+
val += c;
|
579
|
+
break;
|
580
|
+
case '[':
|
581
|
+
if ('val' == state()) states.push('array');
|
582
|
+
val += c;
|
583
|
+
break;
|
584
|
+
case ']':
|
585
|
+
if ('array' == state()) states.pop();
|
586
|
+
val += c;
|
587
|
+
break;
|
588
|
+
case '"':
|
589
|
+
case "'":
|
590
|
+
switch (state()) {
|
591
|
+
case 'key':
|
592
|
+
states.push('key char');
|
593
|
+
break;
|
594
|
+
case 'key char':
|
595
|
+
states.pop();
|
596
|
+
break;
|
597
|
+
case 'string':
|
598
|
+
if (c == quote) states.pop();
|
599
|
+
val += c;
|
600
|
+
break;
|
601
|
+
default:
|
602
|
+
states.push('string');
|
603
|
+
val += c;
|
604
|
+
quote = c;
|
605
|
+
}
|
606
|
+
break;
|
607
|
+
case '':
|
608
|
+
break;
|
609
|
+
default:
|
610
|
+
switch (state()) {
|
611
|
+
case 'key':
|
612
|
+
case 'key char':
|
613
|
+
key += c;
|
614
|
+
break;
|
615
|
+
default:
|
616
|
+
val += c;
|
617
|
+
}
|
618
|
+
}
|
619
|
+
p = c;
|
620
|
+
}
|
621
|
+
|
622
|
+
for (var i = 0; i < len; ++i) {
|
623
|
+
parse(str.charAt(i));
|
624
|
+
}
|
625
|
+
|
626
|
+
parse(',');
|
627
|
+
|
628
|
+
if ('/' == this.input.charAt(0)) {
|
629
|
+
this.consume(1);
|
630
|
+
tok.selfClosing = true;
|
631
|
+
}
|
632
|
+
|
633
|
+
return tok;
|
634
|
+
}
|
635
|
+
},
|
636
|
+
|
637
|
+
/**
|
638
|
+
* Indent | Outdent | Newline.
|
639
|
+
*/
|
640
|
+
|
641
|
+
indent: function() {
|
642
|
+
var captures, re;
|
643
|
+
|
644
|
+
// established regexp
|
645
|
+
if (this.indentRe) {
|
646
|
+
captures = this.indentRe.exec(this.input);
|
647
|
+
// determine regexp
|
648
|
+
} else {
|
649
|
+
// tabs
|
650
|
+
re = /^\n(\t*) */;
|
651
|
+
captures = re.exec(this.input);
|
652
|
+
|
653
|
+
// spaces
|
654
|
+
if (captures && !captures[1].length) {
|
655
|
+
re = /^\n( *)/;
|
656
|
+
captures = re.exec(this.input);
|
657
|
+
}
|
658
|
+
|
659
|
+
// established
|
660
|
+
if (captures && captures[1].length) this.indentRe = re;
|
661
|
+
}
|
662
|
+
|
663
|
+
if (captures) {
|
664
|
+
var tok
|
665
|
+
, indents = captures[1].length;
|
666
|
+
|
667
|
+
++this.lineno;
|
668
|
+
this.consume(indents + 1);
|
669
|
+
|
670
|
+
if (' ' == this.input[0] || '\t' == this.input[0]) {
|
671
|
+
throw new Error('Invalid indentation, you can use tabs or spaces but not both');
|
672
|
+
}
|
673
|
+
|
674
|
+
// blank line
|
675
|
+
if ('\n' == this.input[0]) return this.tok('newline');
|
676
|
+
|
677
|
+
// outdent
|
678
|
+
if (this.indentStack.length && indents < this.indentStack[0]) {
|
679
|
+
while (this.indentStack.length && this.indentStack[0] > indents) {
|
680
|
+
this.stash.push(this.tok('outdent'));
|
681
|
+
this.indentStack.shift();
|
682
|
+
}
|
683
|
+
tok = this.stash.pop();
|
684
|
+
// indent
|
685
|
+
} else if (indents && indents != this.indentStack[0]) {
|
686
|
+
this.indentStack.unshift(indents);
|
687
|
+
tok = this.tok('indent', indents);
|
688
|
+
// newline
|
689
|
+
} else {
|
690
|
+
tok = this.tok('newline');
|
691
|
+
}
|
692
|
+
|
693
|
+
return tok;
|
694
|
+
}
|
695
|
+
},
|
696
|
+
|
697
|
+
/**
|
698
|
+
* Pipe-less text consumed only when
|
699
|
+
* pipeless is true;
|
700
|
+
*/
|
701
|
+
|
702
|
+
pipelessText: function() {
|
703
|
+
if (this.pipeless) {
|
704
|
+
if ('\n' == this.input[0]) return;
|
705
|
+
var i = this.input.indexOf('\n');
|
706
|
+
if (-1 == i) i = this.input.length;
|
707
|
+
var str = this.input.substr(0, i);
|
708
|
+
this.consume(str.length);
|
709
|
+
return this.tok('text', str);
|
710
|
+
}
|
711
|
+
},
|
712
|
+
|
713
|
+
/**
|
714
|
+
* ':'
|
715
|
+
*/
|
716
|
+
|
717
|
+
colon: function() {
|
718
|
+
return this.scan(/^: */, ':');
|
719
|
+
},
|
720
|
+
|
721
|
+
/**
|
722
|
+
* Return the next token object, or those
|
723
|
+
* previously stashed by lookahead.
|
724
|
+
*
|
725
|
+
* @return {Object}
|
726
|
+
* @api private
|
727
|
+
*/
|
728
|
+
|
729
|
+
advance: function(){
|
730
|
+
return this.stashed()
|
731
|
+
|| this.next();
|
732
|
+
},
|
733
|
+
|
734
|
+
/**
|
735
|
+
* Return the next token object.
|
736
|
+
*
|
737
|
+
* @return {Object}
|
738
|
+
* @api private
|
739
|
+
*/
|
740
|
+
|
741
|
+
next: function() {
|
742
|
+
return this.deferred()
|
743
|
+
|| this.blank()
|
744
|
+
|| this.eos()
|
745
|
+
|| this.pipelessText()
|
746
|
+
|| this.yield()
|
747
|
+
|| this.doctype()
|
748
|
+
|| this.interpolation()
|
749
|
+
|| this["case"]()
|
750
|
+
|| this.when()
|
751
|
+
|| this["default"]()
|
752
|
+
|| this["extends"]()
|
753
|
+
|| this.append()
|
754
|
+
|| this.prepend()
|
755
|
+
|| this.block()
|
756
|
+
|| this.include()
|
757
|
+
|| this.mixin()
|
758
|
+
|| this.call()
|
759
|
+
|| this.conditional()
|
760
|
+
|| this.each()
|
761
|
+
|| this["while"]()
|
762
|
+
|| this.assignment()
|
763
|
+
|| this.tag()
|
764
|
+
|| this.filter()
|
765
|
+
|| this.code()
|
766
|
+
|| this.id()
|
767
|
+
|| this.className()
|
768
|
+
|| this.attrs()
|
769
|
+
|| this.indent()
|
770
|
+
|| this.comment()
|
771
|
+
|| this.colon()
|
772
|
+
|| this.text();
|
773
|
+
}
|
774
|
+
};
|