Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

initial commit

  • Loading branch information...
commit f33275345e10af7a43224c7c95f4adf960116071 0 parents
@gushov authored
Showing with 21,259 additions and 0 deletions.
  1. +1 −0  .npmignore
  2. +22 −0 LICENSE-MIT
  3. +27 −0 README.md
  4. +39 −0 grunt.js
  5. +172 −0 lib/lilmodel.js
  6. +1 −0  node_modules/.bin/grunt
  7. +1 −0  node_modules/grunt/.npmignore
  8. +22 −0 node_modules/grunt/LICENSE-MIT
  9. +76 −0 node_modules/grunt/README.md
  10. +16 −0 node_modules/grunt/bin/grunt
  11. +153 −0 node_modules/grunt/dev/init.exp
  12. +1 −0  node_modules/grunt/docs/README.md
  13. +410 −0 node_modules/grunt/docs/api.md
  14. +94 −0 node_modules/grunt/docs/api_config.md
  15. +35 −0 node_modules/grunt/docs/api_fail.md
  16. +184 −0 node_modules/grunt/docs/api_file.md
  17. +144 −0 node_modules/grunt/docs/api_log.md
  18. +416 −0 node_modules/grunt/docs/api_task.md
  19. +72 −0 node_modules/grunt/docs/api_template.md
  20. +126 −0 node_modules/grunt/docs/api_utils.md
  21. +51 −0 node_modules/grunt/docs/contributing.md
  22. +14 −0 node_modules/grunt/docs/example_gruntfiles.md
  23. +16 −0 node_modules/grunt/docs/exit_codes.md
  24. +42 −0 node_modules/grunt/docs/faq.md
  25. +138 −0 node_modules/grunt/docs/getting_started.md
  26. +27 −0 node_modules/grunt/docs/helpers_directives.md
  27. +50 −0 node_modules/grunt/docs/plugins.md
  28. +169 −0 node_modules/grunt/docs/task_concat.md
  29. +186 −0 node_modules/grunt/docs/task_init.md
  30. +188 −0 node_modules/grunt/docs/task_lint.md
  31. +192 −0 node_modules/grunt/docs/task_min.md
  32. +118 −0 node_modules/grunt/docs/task_qunit.md
  33. +75 −0 node_modules/grunt/docs/task_server.md
  34. +42 −0 node_modules/grunt/docs/toc.md
  35. +252 −0 node_modules/grunt/docs/types_of_tasks.md
  36. +87 −0 node_modules/grunt/grunt.js
  37. +151 −0 node_modules/grunt/lib/grunt.js
  38. +115 −0 node_modules/grunt/lib/grunt/cli.js
  39. +129 −0 node_modules/grunt/lib/grunt/config.js
  40. +85 −0 node_modules/grunt/lib/grunt/fail.js
  41. +240 −0 node_modules/grunt/lib/grunt/file.js
  42. +69 −0 node_modules/grunt/lib/grunt/help.js
  43. +273 −0 node_modules/grunt/lib/grunt/log.js
  44. +40 −0 node_modules/grunt/lib/grunt/option.js
  45. +388 −0 node_modules/grunt/lib/grunt/task.js
  46. +80 −0 node_modules/grunt/lib/grunt/template.js
  47. +110 −0 node_modules/grunt/lib/grunt/utils.js
  48. +21 −0 node_modules/grunt/lib/util/findup.js
  49. +61 −0 node_modules/grunt/lib/util/namespace.js
  50. +390 −0 node_modules/grunt/lib/util/task.js
  51. +1 −0  node_modules/grunt/node_modules/.bin/gunzip-js
  52. +1 −0  node_modules/grunt/node_modules/.bin/gzip-js
  53. +1 −0  node_modules/grunt/node_modules/.bin/jshint
  54. +1 −0  node_modules/grunt/node_modules/.bin/nodeunit
  55. +1 −0  node_modules/grunt/node_modules/.bin/nopt
  56. +1 −0  node_modules/grunt/node_modules/.bin/semver
  57. +1 −0  node_modules/grunt/node_modules/.bin/uglifyjs
  58. +9 −0 node_modules/grunt/node_modules/async/.gitmodules
  59. +4 −0 node_modules/grunt/node_modules/async/.npmignore
  60. +19 −0 node_modules/grunt/node_modules/async/LICENSE
  61. +25 −0 node_modules/grunt/node_modules/async/Makefile
  62. +1,022 −0 node_modules/grunt/node_modules/async/README.md
  63. +3 −0  node_modules/grunt/node_modules/async/index.js
  64. +692 −0 node_modules/grunt/node_modules/async/lib/async.js
  65. +21 −0 node_modules/grunt/node_modules/async/package.json
  66. +22 −0 node_modules/grunt/node_modules/colors/MIT-LICENSE.txt
  67. +77 −0 node_modules/grunt/node_modules/colors/ReadMe.md
  68. +269 −0 node_modules/grunt/node_modules/colors/colors.js
  69. +74 −0 node_modules/grunt/node_modules/colors/example.html
  70. +65 −0 node_modules/grunt/node_modules/colors/example.js
  71. +14 −0 node_modules/grunt/node_modules/colors/package.json
  72. +65 −0 node_modules/grunt/node_modules/colors/test.js
  73. +11 −0 node_modules/grunt/node_modules/connect/.npmignore
  74. +24 −0 node_modules/grunt/node_modules/connect/LICENSE
  75. +2 −0  node_modules/grunt/node_modules/connect/index.js
  76. +81 −0 node_modules/grunt/node_modules/connect/lib/cache.js
  77. +106 −0 node_modules/grunt/node_modules/connect/lib/connect.js
  78. +218 −0 node_modules/grunt/node_modules/connect/lib/http.js
  79. +47 −0 node_modules/grunt/node_modules/connect/lib/https.js
  80. +46 −0 node_modules/grunt/node_modules/connect/lib/index.js
  81. +93 −0 node_modules/grunt/node_modules/connect/lib/middleware/basicAuth.js
  82. +196 −0 node_modules/grunt/node_modules/connect/lib/middleware/bodyParser.js
  83. +163 −0 node_modules/grunt/node_modules/connect/lib/middleware/compiler.js
  84. +46 −0 node_modules/grunt/node_modules/connect/lib/middleware/cookieParser.js
  85. +105 −0 node_modules/grunt/node_modules/connect/lib/middleware/csrf.js
  86. +222 −0 node_modules/grunt/node_modules/connect/lib/middleware/directory.js
  87. +100 −0 node_modules/grunt/node_modules/connect/lib/middleware/errorHandler.js
  88. +76 −0 node_modules/grunt/node_modules/connect/lib/middleware/favicon.js
  89. +80 −0 node_modules/grunt/node_modules/connect/lib/middleware/limit.js
  90. +299 −0 node_modules/grunt/node_modules/connect/lib/middleware/logger.js
  91. +38 −0 node_modules/grunt/node_modules/connect/lib/middleware/methodOverride.js
  92. +100 −0 node_modules/grunt/node_modules/connect/lib/middleware/profiler.js
  93. +40 −0 node_modules/grunt/node_modules/connect/lib/middleware/query.js
  94. +34 −0 node_modules/grunt/node_modules/connect/lib/middleware/responseTime.js
  95. +379 −0 node_modules/grunt/node_modules/connect/lib/middleware/router.js
  96. +345 −0 node_modules/grunt/node_modules/connect/lib/middleware/session.js
  97. +126 −0 node_modules/grunt/node_modules/connect/lib/middleware/session/cookie.js
  98. +131 −0 node_modules/grunt/node_modules/connect/lib/middleware/session/memory.js
  99. +137 −0 node_modules/grunt/node_modules/connect/lib/middleware/session/session.js
  100. +87 −0 node_modules/grunt/node_modules/connect/lib/middleware/session/store.js
  101. +225 −0 node_modules/grunt/node_modules/connect/lib/middleware/static.js
  102. +175 −0 node_modules/grunt/node_modules/connect/lib/middleware/staticCache.js
  103. +44 −0 node_modules/grunt/node_modules/connect/lib/middleware/vhost.js
  104. +79 −0 node_modules/grunt/node_modules/connect/lib/patch.js
  105. +75 −0 node_modules/grunt/node_modules/connect/lib/public/directory.html
  106. +13 −0 node_modules/grunt/node_modules/connect/lib/public/error.html
  107. BIN  node_modules/grunt/node_modules/connect/lib/public/favicon.ico
  108. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page.png
  109. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_add.png
  110. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_attach.png
  111. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_code.png
  112. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_copy.png
  113. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_delete.png
  114. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_edit.png
  115. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_error.png
  116. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_excel.png
  117. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_find.png
  118. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_gear.png
  119. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_go.png
  120. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_green.png
  121. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_key.png
  122. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_lightning.png
  123. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_link.png
  124. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_paintbrush.png
  125. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_paste.png
  126. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_red.png
  127. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_refresh.png
  128. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_save.png
  129. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white.png
  130. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_acrobat.png
  131. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_actionscript.png
  132. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_add.png
  133. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_c.png
  134. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_camera.png
  135. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_cd.png
  136. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_code.png
  137. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_code_red.png
  138. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_coldfusion.png
  139. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_compressed.png
  140. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_copy.png
  141. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_cplusplus.png
  142. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_csharp.png
  143. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_cup.png
  144. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_database.png
  145. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_delete.png
  146. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_dvd.png
  147. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_edit.png
  148. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_error.png
  149. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_excel.png
  150. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_find.png
  151. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_flash.png
  152. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_freehand.png
  153. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_gear.png
  154. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_get.png
  155. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_go.png
  156. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_h.png
  157. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_horizontal.png
  158. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_key.png
  159. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_lightning.png
  160. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_link.png
  161. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_magnify.png
  162. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_medal.png
  163. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_office.png
  164. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_paint.png
  165. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_paintbrush.png
  166. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_paste.png
  167. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_php.png
  168. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_picture.png
  169. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_powerpoint.png
  170. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_put.png
  171. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_ruby.png
  172. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_stack.png
  173. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_star.png
  174. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_swoosh.png
  175. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_text.png
  176. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_text_width.png
  177. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_tux.png
  178. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_vector.png
  179. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_visualstudio.png
  180. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_width.png
  181. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_word.png
  182. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_world.png
  183. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_wrench.png
  184. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_white_zip.png
  185. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_word.png
  186. BIN  node_modules/grunt/node_modules/connect/lib/public/icons/page_world.png
  187. +141 −0 node_modules/grunt/node_modules/connect/lib/public/style.css
  188. +451 −0 node_modules/grunt/node_modules/connect/lib/utils.js
  189. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/..travis.yml.un~
  190. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/.Readme.md.un~
  191. +4 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/.npmignore
  192. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/.package.json.un~
  193. +4 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/.travis.yml
  194. +14 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/Makefile
  195. +303 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/Readme.md
  196. +3 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/TODO
  197. +70 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/benchmark/bench-multipart-parser.js
  198. +43 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/example/post.js
  199. +48 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/example/upload.js
  200. +1 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/index.js
  201. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/lib/.incoming_form.js.un~
  202. +61 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/lib/file.js
  203. +378 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/lib/incoming_form.js
  204. +3 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/lib/index.js
  205. +312 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/lib/multipart_parser.js
  206. +25 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/lib/querystring_parser.js
  207. +6 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/lib/util.js
  208. +22 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/package.json
  209. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/.common.js.un~
  210. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/.run.js.un~
  211. +19 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/common.js
  212. +1 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/file/funkyfilename.txt
  213. +1 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/file/plain.txt
  214. BIN  ..._modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/http/no-filename/.generic.http.un~
  215. +3 −0  ...ules/grunt/node_modules/connect/node_modules/formidable/test/fixture/http/special-chars-in-filename/info.md
  216. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/js/.no-filename.js.un~
  217. BIN  ...odules/grunt/node_modules/connect/node_modules/formidable/test/fixture/js/.special-chars-in-filename.js.un~
  218. +3 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/js/no-filename.js
  219. +21 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/js/special-chars-in-filename.js
  220. +72 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/fixture/multipart.js
  221. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/integration/.test-fixtures.js.un~
  222. +89 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/integration/test-fixtures.js
  223. +24 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/common.js
  224. +80 −0 ...modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/integration/test-multipart-parser.js
  225. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/simple/.test-incoming-form.js.un~
  226. +104 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/simple/test-file.js
  227. +726 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/simple/test-incoming-form.js
  228. +50 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/simple/test-multipart-parser.js
  229. +45 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/simple/test-querystring-parser.js
  230. BIN  ...dules/grunt/node_modules/connect/node_modules/formidable/test/legacy/system/.test-multi-video-upload.js.un~
  231. +72 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/legacy/system/test-multi-video-upload.js
  232. +2 −0  node_modules/grunt/node_modules/connect/node_modules/formidable/test/run.js
  233. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/system/.test-mail-fixture.js.un~
  234. 0  node_modules/grunt/node_modules/connect/node_modules/formidable/test/tmp/.empty
  235. BIN  node_modules/grunt/node_modules/connect/node_modules/formidable/test/unit/.test-incoming-form.js.un~
  236. +63 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/test/unit/test-incoming-form.js
  237. +47 −0 node_modules/grunt/node_modules/connect/node_modules/formidable/tool/record.js
  238. +19 −0 node_modules/grunt/node_modules/connect/node_modules/mime/LICENSE
  239. +63 −0 node_modules/grunt/node_modules/connect/node_modules/mime/README.md
  240. +93 −0 node_modules/grunt/node_modules/connect/node_modules/mime/mime.js
  241. +22 −0 node_modules/grunt/node_modules/connect/node_modules/mime/package.json
  242. +53 −0 node_modules/grunt/node_modules/connect/node_modules/mime/test.js
  243. +1,510 −0 node_modules/grunt/node_modules/connect/node_modules/mime/types/mime.types
  244. +48 −0 node_modules/grunt/node_modules/connect/node_modules/mime/types/node.types
  245. +6 −0 node_modules/grunt/node_modules/connect/node_modules/qs/.gitmodules
  246. +1 −0  node_modules/grunt/node_modules/connect/node_modules/qs/.npmignore
  247. +4 −0 node_modules/grunt/node_modules/connect/node_modules/qs/.travis.yml
  248. +73 −0 node_modules/grunt/node_modules/connect/node_modules/qs/History.md
  249. +5 −0 node_modules/grunt/node_modules/connect/node_modules/qs/Makefile
  250. +54 −0 node_modules/grunt/node_modules/connect/node_modules/qs/Readme.md
  251. +17 −0 node_modules/grunt/node_modules/connect/node_modules/qs/benchmark.js
  252. +51 −0 node_modules/grunt/node_modules/connect/node_modules/qs/examples.js
  253. +2 −0  node_modules/grunt/node_modules/connect/node_modules/qs/index.js
  254. +264 −0 node_modules/grunt/node_modules/connect/node_modules/qs/lib/querystring.js
  255. +16 −0 node_modules/grunt/node_modules/connect/node_modules/qs/package.json
  256. +2 −0  node_modules/grunt/node_modules/connect/node_modules/qs/test/mocha.opts
  257. +167 −0 node_modules/grunt/node_modules/connect/node_modules/qs/test/parse.js
  258. +103 −0 node_modules/grunt/node_modules/connect/node_modules/qs/test/stringify.js
  259. +26 −0 node_modules/grunt/node_modules/connect/package.json
  260. +1 −0  node_modules/grunt/node_modules/connect/test/fixtures/.hidden
  261. 0  node_modules/grunt/node_modules/connect/test/fixtures/directory/.hidden
  262. +67 −0 node_modules/grunt/node_modules/dateformat/Readme.md
  263. +165 −0 node_modules/grunt/node_modules/dateformat/lib/dateformat.js
  264. +14 −0 node_modules/grunt/node_modules/dateformat/package.json
  265. +4 −0 node_modules/grunt/node_modules/dateformat/test/test_weekofyear.js
  266. +27 −0 node_modules/grunt/node_modules/dateformat/test/test_weekofyear.sh
  267. +1 −0  node_modules/grunt/node_modules/glob-whatev/.npmignore
  268. +22 −0 node_modules/grunt/node_modules/glob-whatev/LICENSE-MIT
  269. +50 −0 node_modules/grunt/node_modules/glob-whatev/README.md
  270. +39 −0 node_modules/grunt/node_modules/glob-whatev/grunt.js
  271. +101 −0 node_modules/grunt/node_modules/glob-whatev/lib/glob.js
  272. +4 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/.travis.yml
  273. +23 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/LICENSE
  274. +218 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/README.md
  275. +1,052 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/minimatch.js
  276. +1 −0  node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/.npmignore
  277. +23 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/LICENSE
  278. +14 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/README.md
  279. +106 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js
  280. +13 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/package.json
  281. +117 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/node_modules/lru-cache/test/basic.js
  282. +29 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/package.json
  283. +273 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/test/basic.js
  284. +33 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/test/brace-expand.js
  285. +14 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/test/caching.js
  286. +274 −0 node_modules/grunt/node_modules/glob-whatev/node_modules/minimatch/test/defaults.js
  287. +42 −0 node_modules/grunt/node_modules/glob-whatev/package.json
  288. 0  node_modules/grunt/node_modules/glob-whatev/test/fixture/boot
  289. 0  node_modules/grunt/node_modules/glob-whatev/test/fixture/foo/bar/baz/boot
  290. 0  node_modules/grunt/node_modules/glob-whatev/test/fixture/foo/bar/boot
  291. 0  node_modules/grunt/node_modules/glob-whatev/test/fixture/foo/boot
  292. +109 −0 node_modules/grunt/node_modules/glob-whatev/test/glob_test.js
  293. +3 −0  node_modules/grunt/node_modules/gzip-js/.npmignore
  294. +33 −0 node_modules/grunt/node_modules/gzip-js/README.md
  295. +27 −0 node_modules/grunt/node_modules/gzip-js/bin/gunzip.js
  296. +30 −0 node_modules/grunt/node_modules/gzip-js/bin/gzip.js
  297. +275 −0 node_modules/grunt/node_modules/gzip-js/lib/gzip.js
  298. +1 −0  node_modules/grunt/node_modules/gzip-js/node_modules/.bin/crc32
  299. +1 −0  node_modules/grunt/node_modules/gzip-js/node_modules/.bin/deflate-js
  300. +1 −0  node_modules/grunt/node_modules/gzip-js/node_modules/.bin/inflate-js
Sorry, we could not display the entire diff because too many files (1,186) changed.
1  .npmignore
@@ -0,0 +1 @@
+/node_modules/
22 LICENSE-MIT
@@ -0,0 +1,22 @@
+Copyright (c) 2012 August Hovland
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
27 README.md
@@ -0,0 +1,27 @@
+# model
+
+The best project ever.
+
+## Getting Started
+Install the module with: `npm install model`
+
+```javascript
+var model = require('model');
+model.awesome(); // "awesome"
+```
+
+## Documentation
+_(Coming soon)_
+
+## Examples
+_(Coming soon)_
+
+## Contributing
+In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [grunt](https://github.com/cowboy/grunt).
+
+## Release History
+_(Nothing yet)_
+
+## License
+Copyright (c) 2012 August Hovland
+Licensed under the MIT license.
39 grunt.js
@@ -0,0 +1,39 @@
+module.exports = function(grunt) {
+
+ // Project configuration.
+ grunt.initConfig({
+ pkg: '<json:package.json>',
+ test: {
+ files: ['test/**/*.js']
+ },
+ lint: {
+ files: ['grunt.js', 'lib/**/*.js', 'test/**/*.js']
+ },
+ watch: {
+ files: '<config:lint.files>',
+ tasks: 'default'
+ },
+ jshint: {
+ options: {
+ curly: true,
+ eqeqeq: true,
+ immed: true,
+ latedef: true,
+ newcap: true,
+ noarg: true,
+ sub: true,
+ undef: true,
+ boss: true,
+ eqnull: true,
+ node: true
+ },
+ globals: {
+ exports: true
+ }
+ }
+ });
+
+ // Default task.
+ grunt.registerTask('default', 'lint test');
+
+};
172 lib/lilmodel.js
@@ -0,0 +1,172 @@
+/**
+ * lilmodel
+ * https://github.com/ahovland-nokia/model
+ *
+ * Copyright (c) 2012 August Hovland
+ * Licensed under the MIT license.
+ */
+
+(function (exports) {
+
+ "use strict";
+
+ var sync;
+ var model = {
+ /**
+ * Create instance of model
+ */
+ create: function (attrs) {
+
+ var instance = Object.create(this, {
+ attrs: {
+ value: {},
+ writable: true,
+ enumerable: false,
+ configurable : false
+ }
+ });
+
+ return instance.init(attrs);
+
+ },
+
+ /**
+ * Create a collection of models
+ */
+ collection: function (attrs) {
+
+ var models = [];
+
+ if (attrs && attrs.length) {
+
+ models = attrs.map(function (attr) {
+ return Object.getPrototypeOf(attr) === this ? attr : this.create(attr);
+ }.bind(this));
+
+ }
+
+ return models;
+
+ },
+
+ /**
+ * Model init function sets property values
+ */
+ init: function (attrs) {
+
+ var config = this.config;
+
+ Object.keys(config).forEach(function (prop) {
+
+ var dfault = config && typeof config[prop] !== 'function' ? config[prop] : undefined;
+ this[prop] = attrs && typeof attrs[prop] !== 'undefined' ? attrs[prop] : dfault;
+
+ }.bind(this));
+
+ return this;
+ },
+
+ /**
+ * Method should be overridden to validate this.attrs values
+ */
+ validate: function () {
+ return { isValid: true };
+ },
+
+ /**
+ * If model is valid call sync save
+ */
+ save: function (next) {
+
+ var validator = this.validate();
+ var method = this._id ? 'update' : 'create';
+
+ if (validator.isValid) {
+ sync(method, this, next);
+ } else {
+ next(validator.error);
+ }
+
+ },
+
+ /**
+ * Call sync fetch
+ */
+ fetch: function (next) {
+ sync('fetch', this, next);
+ },
+
+ /**
+ * Call sync find
+ */
+ find: function (next) {
+ sync('find', this, next);
+ },
+
+ /**
+ * Call sync destroy
+ */
+ destroy: function (next) {
+ sync('delete', this, next);
+ },
+
+ //******** DELETE TEMP FUNCTION*********//
+ serialize: function () {
+ return this;
+ }
+ };
+
+ exports.sync = function (handler) {
+
+ sync = function (method, model, next) {
+
+ handler(method, model, function (err, result) {
+
+ if (err) {
+ next(err);
+ } else if (result && typeof result.length === 'number') {
+ next(err, model.collection(result));
+ } else {
+ next(err, model.create(result));
+ }
+
+ });
+
+ };
+
+ };
+
+ exports.model = function (props) {
+
+ var instance = Object.create(model);
+
+ Object.keys(props).forEach(function (prop) {
+
+ var isModel = typeof props[prop] === 'function';
+
+ Object.defineProperty(instance, prop, {
+
+ get: function () {
+ return typeof this.attrs[prop] !== 'undefined' ? this.attrs[prop] : '';
+ },
+
+ set: function (value) {
+ this.attrs[prop] = isModel ? props[prop](value) : value;
+ }
+
+ });
+
+ });
+
+ Object.defineProperty(instance, 'config', {
+ value: props,
+ writable: true,
+ enumerable: false,
+ configurable: false
+ });
+
+ return instance;
+
+ };
+
+}(typeof exports === 'undefined' ? (this.lilmodel = {}) : exports));
1  node_modules/.bin/grunt
1  node_modules/grunt/.npmignore
@@ -0,0 +1 @@
+/node_modules/
22 node_modules/grunt/LICENSE-MIT
@@ -0,0 +1,22 @@
+Copyright (c) 2012 "Cowboy" Ben Alman
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
76 node_modules/grunt/README.md
@@ -0,0 +1,76 @@
+# grunt
+Grunt is a task-based command line build tool for JavaScript projects.
+
+_Grunt is currently in beta. While I'm already using it on multiple projects, it might have a minor issue or two. And things might change before its final release, based on your feedback. Please try it out in a project, and [make suggestions][issues] or [report bugs][issues]!_
+
+## Getting started <a name="getting-started" href="#getting-started" title="Link to this section">⚑</a>
+Be sure to read the [getting started guide](/cowboy/grunt/blob/master/docs/getting_started.md), which is a complete guide to configuring grunt for your project. In addition, check out the [example gruntfiles](/cowboy/grunt/blob/master/docs/example_gruntfiles.md) which highlight a number of fairly common configurations.
+
+## Built-in tasks <a name="built-in-tasks" href="#built-in-tasks" title="Link to this section">⚑</a>
+As of now, grunt has the following predefined tasks that you can use in your project:
+
+* [concat](/cowboy/grunt/blob/master/docs/task_concat.md) - Concatenate files.
+* [init](/cowboy/grunt/blob/master/docs/task_init.md) - Generate project scaffolding from a predefined template.
+* [lint](/cowboy/grunt/blob/master/docs/task_lint.md) - Validate files with [JSHint][jshint].
+* [min](/cowboy/grunt/blob/master/docs/task_min.md) - Minify files with [UglifyJS][uglify].
+* [qunit](/cowboy/grunt/blob/master/docs/task_qunit.md) - Run [QUnit][qunit] unit tests in a headless [PhantomJS][phantom] instance.
+* [server](/cowboy/grunt/blob/master/docs/task_server.md) - Start a static web server.
+* test - Run unit tests with [nodeunit][nodeunit].
+* watch - Run predefined tasks whenever watched files change.
+
+_(More documentation forthcoming)_
+
+## Custom tasks <a name="custom-tasks" href="#custom-tasks" title="Link to this section">⚑</a>
+In addition to the built-in tasks, you can create your own tasks. Don't like a built-in task's default behavior? Override it. Check out the [grunt API documentation](/cowboy/grunt/blob/master/docs/api.md) and the [built-in tasks source](/cowboy/grunt/blob/master/tasks) for everything you need to know about creating custom tasks.
+
+## Documentation <a name="documentation" href="#documentation" title="Link to this section">⚑</a>
+Take a look at the [documentation table of contents][docs] for all the things.
+
+## Why does grunt exist? <a name="why-does-grunt-exist" href="#why-does-grunt-exist" title="Link to this section">⚑</a>
+Doing all this stuff manually is a total pain, and building all this stuff into a gigantic Makefile / Jakefile / Cakefile / Rakefile / ?akefile that's maintained across all my projects was also becoming a total pain. Since I always found myself performing the same tasks over and over again, for every project, it made sense to build a task-based build tool.
+
+Being primarily a JavaScript developer, I decided to use [Node.js][node] and [npm][npm] because the dependencies I most care about ([JSHint][jshint] and [UglifyJS][uglify]) were already npm modules. That being said, while Node.js was designed to support highly-concurrent asynchronous-IO-driven web servers, it was clearly NOT designed to make command-line build tools. But none of that matters, because grunt works. Just install it and see.
+
+## Installing grunt <a name="installing-grunt" href="#installing-grunt" title="Link to this section">⚑</a>
+
+Grunt is available as an [npm][npm] module. If you install grunt globally via `npm install -g grunt`, it will be available for use in all of your projects. Once grunt has been installed, you can type `grunt --help` at the command line for more information. And if you want to see grunt "grunt" itself, cd into grunt's directory and type `grunt`
+
+_Note: in Windows, you may need to run grunt as `grunt.cmd`. See the [FAQ](/cowboy/grunt/blob/master/docs/faq.md) for more Windows-specific information._
+
+For projects already using grunt, you're done. Otherwise, if you're adding grunt to an existing project or starting from scratch, check out the [getting started guide](/cowboy/grunt/blob/master/docs/getting_started.md), which is a complete guide to configuring grunt for your project.
+
+## Release History <a name="release-history" href="#release-history" title="Link to this section">⚑</a>
+_(Until v1.0.0, this will only be updated when major or breaking changes are made)_
+
+* 2012/04/18 - v0.3.9 - The min task (via the uglify helper) now appends a semicolon to the end of the generated source.
+* 2012/04/06 - v0.3.8 - Init template tweaks. Anchor links added to docs, along with grunt-internal docs task to generate them. The watch task now supports multiple targets with separate wildcards and tasks. Locally-installed grunt will override global grunt even when run from global "grunt" script.
+* 2012/04/01 - v0.3.7 - Tweaked the behavior of the init template `exports.warnOn` property and added more init template documentation. Fixed duplicate PhantomJS debug output in qunit task. Added useful nodeunit and qunit comments into init template generated test .js files.
+* 2012/03/28 - v0.3.6 - Fixed a `--help` screen issue, a few grunt plugin related issues, and attempted to improve the overall grunt plugin docs and API.
+* 2012/03/27 - v0.3.5 - Fixed a handful of weird Windows issues. Changed default m/d/yyyy dates to yyyy-mm-dd ISO 8601. Fixed some init task bugs, docs errata, and added a lot more content to the init task docs.
+* 2012/03/26 - v0.3.3 - Added a "gruntfile" init template. Create a basic gruntfile in seconds with `grunt init:gruntfile`. A few other minor fixes.
+* 2012/03/25 - v0.3.2 - Init tasks can now specify a file matching wildcard for the initial "files exist" warning. The jQuery init template now has jQuery 1.7.2. Fixed a bug in the `task.expand*` methods.
+* 2012/03/25 - v0.3.1 - Added a few methods. Substantially reworked the init task and templates.
+* 2012/03/23 - v0.3.0 - Too many changes to list. But in brief: completely reorganized the API, removed all globals, added docs and examples for nearly everything, built a preliminary plugin system (that still needs to be tested). PLEASE RTFM OK? THX U.
+* 2012/02/03 - v0.2.14 - Added a server task (which starts a static webserver for your tasks). The qunit task now uses PhantomJS instead of Zombie.js (4768 of 4971 jQuery unit test pass, neat), and supports both file wildcards as well as http:// or https:// urls. (static webserver, anyone?). Grunt should no longer "hang" when done.
+* 2012/01/29 - v0.2.5 - Added a "qunit" task as well as an init "jquery" template (as of now, there are also "node" and "commonjs" init templates).
+* 2012/01/22 - v0.2.1 - Removed handlebars, templates are universally handled by underscore now. Changed init task template tags from <% %> to {% %}. Banners beginning with /*! will no longer be stripped.
+* 2012/01/22 - v0.2.0 - Added "init" task with a sample template, reworked a lot of code. Hopefully it's backwards-compatible.
+* 2012/01/11 - v0.1.0 - Initial release.
+
+## License <a name="license" href="#license" title="Link to this section">⚑</a>
+Copyright (c) 2012 "Cowboy" Ben Alman
+Licensed under the MIT license.
+<http://benalman.com/about/license/>
+
+
+[docs]: /cowboy/grunt/blob/master/docs/toc.md
+[docs-init]: /cowboy/grunt/blob/master/docs/task_init.md
+[issues]: /cowboy/grunt/issues
+
+[node]: http://nodejs.org/
+[npm]: http://npmjs.org/
+[jshint]: http://www.jshint.com/
+[uglify]: https://github.com/mishoo/UglifyJS/
+[nodeunit]: https://github.com/caolan/nodeunit
+[qunit]: http://docs.jquery.com/QUnit
+[phantom]: http://www.phantomjs.org/
16 node_modules/grunt/bin/grunt
@@ -0,0 +1,16 @@
+#!/usr/bin/env node
+
+// Nodejs lib.
+var path = require('path');
+
+// Badass internal grunt lib.
+var findup = require('../lib/util/findup');
+
+// Where might a locally-installed grunt live?
+var dir = path.resolve(findup(process.cwd(), 'grunt.js'), '../node_modules/grunt');
+
+// If grunt is installed locally, use it. Otherwise use this grunt.
+if (!path.existsSync(dir)) { dir = '../lib/grunt'; }
+
+// Run grunt.
+require(dir).cli();
153 node_modules/grunt/dev/init.exp
@@ -0,0 +1,153 @@
+#!/usr/bin/expect -f
+
+# OMG THIS WAS A PAIN TO CREATE
+
+if {$argc == 0} {
+ # No template specified, iterate over all templates.
+ set templates [list jquery commonjs node gruntplugin gruntfile]
+} else {
+ # One or more templates were specified, iterate over those.
+ set templates [lrange $argv 0 end]
+}
+
+foreach template $templates {
+
+set project "grunt-$template-example"
+
+# Disable git pushing when debugging.
+set gitpush 1
+
+# Grunt version
+set version [exec grunt --version]
+
+# Stop any already-running logging.
+log_file
+
+# Start logging fresh, saving output for later use.
+log_file -noappend /tmp/grunt-expect-out
+
+# Spawn bash without all my crazy dotfiles stuff.
+set timeout -1
+spawn bash --noprofile --norc
+match_max 100000
+
+# Make the prompt look nice.
+expect "$ "
+send "PS1='\n$ '\r"
+expect "\r"
+
+# Cleanup any existing session.
+expect "$ "
+send "cd /tmp\r"
+expect "$ "
+send "rm -rf /tmp/$project\r"
+
+# Session logging starts here.
+expect "$ "
+send "mkdir $project && cd $project\r"
+
+# Initialize the current directory.
+expect "$ "
+send "git init\r"
+expect "$ "
+send "git remote add origin git@github.com:cowboy/$project.git\r"
+
+# Note that the "--no-color" will be stripped out later.
+expect "$ "
+send "grunt init:$template --no-color\r"
+
+# Don't start answering prompts until this line is encountered.
+expect "Please answer the following:"
+
+# Loop over all prompts.
+expect {
+ "Do you need to make any changes to the above before continuing? (y/N)" {send "\r"}
+ "Project name (jquery.grunt-jquery-example)" {send "jquery.grunt-example\r"; exp_continue}
+ "Project title (jQuery Grunt Example)" {send "Grunt jQuery Example Plugin\r"; exp_continue}
+ "Description" {send "This is example output generated by the \"grunt init:$template\" task."; exp_continue}
+ ") " {send "\r"; exp_continue}
+}
+
+# Pre-grunt file structure.
+expect "$ "
+send "tree\r"
+
+# Let grunt grunt the newly-created file structure.
+expect "$ "
+send "grunt --no-color\r"
+
+# Post-grunt file structure. Any built files should appear here.
+expect "$ "
+send "tree\r"
+
+# Commit everything.
+expect "$ "
+send "git add .\r"
+expect "$ "
+send "git commit -m 'Committing example \"grunt init:$template\" task output.'\r"
+
+# Session logging stops here.
+expect "$ "
+send "# EOF\n"
+
+# Add meta-content to the README.
+expect "$ "
+send "echo -e '# Grunt \"init:$template\" example
+
+This is example output generated by the \"grunt init:$template\" task.
+
+_Note: this repository was generated dynamically using $version. Instead of
+reporting issues here, please report any issues with this repository as
+\[grunt issues\]\[issues\]. Instead of watching or forking this repository,
+watch \[grunt\]\[grunt\] and use the grunt \[init task\]\[init\]._
+
+## Project Creation Transcript
+The following is a transcript of the session in which this project and
+repository were created. This is not actually a part of the \[grunt\]\[grunt\]
+\"init:$template\" template, this session transcript was added afterwards. The
+text after the `$` are the commands that were executed, and everything else is
+program output. If you want to see the repository exactly as it was created by
+grunt, view \[the previous commit\]\[prev\].' > README.md\r"
+expect "$ "
+send "echo -e '
+Want to learn more? Check \[grunt\]\[grunt\] out.
+
+\[grunt\]: https://github.com/cowboy/grunt
+\[issues\]: https://github.com/cowboy/grunt/issues
+\[init\]: https://github.com/cowboy/grunt/blob/master/docs/task_init.md
+\[expect\]: https://github.com/cowboy/grunt/blob/master/dev/init.exp
+\[prev\]: https://github.com/cowboy/$project/tree/HEAD~1
+
+Note that this entire build process is automated by a rather complex \[expect
+script\]\[expect\], which is used to automate grunt in order to facilitate the
+creation of this and other \[init task\]\[init\] example repositories.
+
+```' >> README.md\r"
+expect "$ "
+# Strip out everything before the "mkdir" and after the "EOF". Also remove any "--no-color" bits.
+send "cat /tmp/grunt-expect-out | perl -ne's/ --no-color//;if(/^\\\$ mkdir/){\$x=1}elsif(/^\\\$ # EOF/){\$x=0}\$x&&print\$_' >> README.md\r"
+expect "$ "
+send "echo -e '```
+
+## License
+Copyright (c) 2012 \"Cowboy\" Ben Alman
+Licensed under the MIT license.' >> README.md\r"
+
+# Commit again.
+expect "$ "
+send "git add .\r"
+expect "$ "
+send "git commit -m 'Adding project creation transcript.'\r"
+
+# Push to GitHub.
+if {$gitpush} {
+ expect "$ "
+ send "git push -uf origin master\r"
+}
+
+expect "$ "
+send "exit\r"
+
+expect eof
+
+}
1  node_modules/grunt/docs/README.md
@@ -0,0 +1 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](/cowboy/grunt/blob/master/docs/toc.md)
410 node_modules/grunt/docs/api.md
@@ -0,0 +1,410 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# The grunt API
+
+Grunt exposes all of its methods and properties on the `grunt` object that gets passed into the `module.exports` function exported in your [grunt.js gruntfile](getting_started.md) or in your [tasks file](types_of_tasks.md).
+
+For example, your project's [grunt.js gruntfile](getting_started.md) might look like this:
+
+```javascript
+module.exports = function(grunt) {
+
+ // Project configuration.
+ grunt.initConfig({
+ lint: {
+ all: ['grunt.js', 'lib/**/*.js', 'test/**/*.js']
+ },
+ jshint: {
+ options: {
+ browser: true
+ }
+ }
+ });
+
+ // Load tasks from "grunt-sample" grunt plugin installed via Npm.
+ grunt.loadNpmTasks('grunt-sample');
+
+ // Default task.
+ grunt.registerTask('default', 'lint sample');
+
+};
+```
+
+And if you're creating a [grunt plugin](plugins.md) or just organizing tasks into a folder, a [custom tasks file](types_of_tasks.md) might look like this:
+
+```javascript
+module.exports = function(grunt) {
+
+ // Create a new task.
+ grunt.registerTask('awesome', 'Print out "awesome!!!"', function() {
+ var awesome = grunt.helper('awesome');
+ grunt.log.write(awesome);
+ });
+
+ // Register a helper.
+ grunt.registerHelper('awesome', function() {
+ return 'awesome!!!';
+ });
+
+};
+```
+
+But these are just examples. For more information, read on.
+
+## A Very Important Note <a name="a-very-important-note" href="#a-very-important-note" title="Link to this section">⚑</a>
+Your `grunt.js` gruntfile or tasks file **must** contain this code, once and **only** once. If it doesn't, things won't work. For the sake of brevity, this "wrapper" code has been omitted from all future examples on this page, but it needs to be there. Like in the previous examples.
+
+```javascript
+module.exports = function(grunt) {
+ // Your grunt code goes in here.
+};
+```
+
+## Config <a name="config" href="#config" title="Link to this section">⚑</a>
+_Note that the method listed below is also available on the [grunt.config](api_config.md) object in addition to the `grunt` object._
+
+
+### grunt.initConfig <a name="grunt-initconfig" href="#grunt-initconfig" title="Link to this section">⚑</a>
+Initialize a configuration object for the current project. The specified `configObject` is used by tasks and helpers and can also be accessed using the [grunt.config](api_config.md) method. Nearly every project's [grunt.js gruntfile](getting_started.md) will call this method.
+
+Note that any specified `<config>` and `<json>` [directives](api_task.md) will be automatically processed when the config object is initialized.
+
+```javascript
+grunt.initConfig(configObject)
+```
+
+This example contains sample config data for the [lint task](task_lint.md):
+
+```javascript
+grunt.initConfig({
+ lint: {
+ all: ['lib/*.js', 'test/*.js', 'grunt.js']
+ }
+});
+```
+
+See the [configuring grunt](getting_started.md) page for more configuration examples.
+
+_This method is an alias for the [grunt.config.init](api_config.md) method._
+
+
+## Creating Tasks <a name="creating-tasks" href="#creating-tasks" title="Link to this section">⚑</a>
+Tasks are grunt's bread and butter. The stuff you do most often, like `lint` or `test`. Every time grunt is run, you specify one or more tasks to run, which tells grunt what you'd like it to do.
+
+If you don't specify a task, but a task named "default" has been defined, that task will run (unsurprisingly) by default.
+
+_Note that the methods listed below are also available on the [grunt.task](api_task.md) object in addition to the `grunt` object._
+
+
+### grunt.registerTask <a name="grunt-registertask" href="#grunt-registertask" title="Link to this section">⚑</a>
+Register an "alias task" or a task function. This method supports the following two signatures:
+
+**Alias task**
+
+If a task list is specified, the new task will be an alias for one or more other tasks. Whenever this "alias task" is run, every specified task in `taskList` will be run, in the order specified. The `taskList` argument can be a space-separated string or an array of task names.
+
+```javascript
+grunt.registerTask(taskName, taskList)
+```
+
+This example alias task defines a "default" task whereby the "lint", "qunit", "concat" and "min" tasks are run automatically if grunt is executed without any tasks specified:
+
+```javascript
+task.registerTask('default', 'lint qunit concat min');
+```
+
+**Function task**
+
+If a `description` and `taskFunction` are passed, the specified function will be executed whenever the task is run. In addition, the specified description will be shown when `grunt --help` is run. Task-specific properties and methods are available inside the task function as properties of the `this` object. The task function can return `false` to indicate that the task has failed.
+
+Note that the `grunt.registerMultiTask` method, explained below, can be used to define a special type of task known as a "multi task."
+
+```javascript
+grunt.registerTask(taskName, description, taskFunction)
+```
+
+This example task logs `foo, testing 123` if grunt is run via `grunt foo:testing:123`. If the task is run without arguments as `grunt foo` the task logs `foo, no args`.
+
+```javascript
+grunt.registerTask('foo', 'A sample task that logs stuff.', function(arg1, arg2) {
+ if (arguments.length === 0) {
+ grunt.log.writeln(this.name + ", no args");
+ } else {
+ grunt.log.writeln(this.name + ", " + arg1 + " " + arg2);
+ }
+});
+```
+
+See the [creating tasks](types_of_tasks.md) documentation for more examples of tasks and alias tasks.
+
+_This method is an alias for the [grunt.task.registerTask](api_task.md) method._
+
+
+### grunt.registerMultiTask <a name="grunt-registermultitask" href="#grunt-registermultitask" title="Link to this section">⚑</a>
+Register a "multi task." A multi task is a task that implicitly iterates over all of its named sub-properties (AKA targets) if no target was specified. In addition to the default properties and methods, extra multi task-specific properties are available inside the task function as properties of the `this` object.
+
+Many of the built-in tasks, including the [lint task](task_lint.md), [concat task](task_concat.md) and [min task](task_min.md) are multi tasks.
+
+```javascript
+grunt.registerMultiTask(taskName, description, taskFunction)
+```
+
+Given the specified configuration, this example multi task would log `foo: 1,2,3` if grunt was run via `grunt log:foo`, or it would log `bar: hello world` if grunt was run via `grunt log:bar`. If grunt was run as `grunt log` however, it would log `foo: 1,2,3` then `bar: hello world` then `baz: false`.
+
+```javascript
+grunt.initConfig({
+ log: {
+ foo: [1, 2, 3],
+ bar: 'hello world',
+ baz: false
+ }
+});
+
+grunt.registerMultiTask('log', 'Log stuff.', function() {
+ grunt.log.writeln(this.target + ': ' + this.data);
+});
+```
+
+See the [creating tasks](types_of_tasks.md) documentation for more examples of multi tasks.
+
+_This method is an alias for the [grunt.task.registerMultiTask](api_task.md) method._
+
+
+### grunt.registerInitTask <a name="grunt-registerinittask" href="#grunt-registerinittask" title="Link to this section">⚑</a>
+Register an "init task." An init task is a task that doesn't require any configuration data, and as such will still run even if grunt can't find a [grunt.js gruntfile](getting_started.md). The included [init task](task_init.md) is an example of an "init task."
+
+```javascript
+grunt.registerInitTask(taskName, description, taskFunction)
+```
+
+For an init task example, see the [init task source](../tasks/init.js).
+
+_This method is an alias for the [grunt.task.registerInitTask](api_task.md) method._
+
+### grunt.renameTask <a name="grunt-renametask" href="#grunt-renametask" title="Link to this section">⚑</a>
+Rename a task. This might be useful if you want to override the default behavior of a task, while retaining the old name.
+
+```javascript
+grunt.renameTask(oldname, newname)
+```
+
+_This method is an alias for the [grunt.task.renameTask](api_task.md) method._
+
+## Inside Tasks <a name="inside-tasks" href="#inside-tasks" title="Link to this section">⚑</a>
+An object is made available as `this` inside each task function that contains a number of useful task-specific properties and methods. This same object is also exposed as `grunt.task.current` for use in [templates](api_template.md).
+
+### this.async / grunt.task.current.async <a name="this-async-grunt-task-current-async" href="#this-async-grunt-task-current-async" title="Link to this section">⚑</a>
+If a task is asynchronous, this method must be invoked to instruct grunt to wait. It returns a handle to a "done" function that should be called when the task has completed. `false` can be passed to the done function to indicate that the task has failed. If this method isn't invoked, the task executes synchronously.
+
+```javascript
+// Tell grunt this task is asynchronous.
+var done = this.async();
+// Your async code.
+setTimeout(function() {
+ // Let's simulate an error, sometimes.
+ var success = Math.random() > 0.5;
+ // All done!
+ done(success);
+}, 1000);
+```
+
+### this.requires / grunt.task.current.requires <a name="this-requires-grunt-task-current-requires" href="#this-requires-grunt-task-current-requires" title="Link to this section">⚑</a>
+If one task depends on the successful completion of another task (or tasks), this method can be used to force grunt to abort if the other task didn't run, or if the other task failed. The task list can be a space-separated string, an array of task names, or individual task name arguments.
+
+Note that this won't actually run the specified task(s), it will just fail the current task if they haven't already run successfully.
+
+```javascript
+this.requires(taskList)
+```
+
+### this.requiresConfig / grunt.task.current.requiresConfig <a name="this-requiresconfig-grunt-task-current-requiresconfig" href="#this-requiresconfig-grunt-task-current-requiresconfig" title="Link to this section">⚑</a>
+Fail the current task if one or more required [config](api_config.md) properties is missing. One or more string or array config properties may be specified.
+
+```javascript
+this.requiresConfig(prop [, prop [, ...]])
+```
+
+See the [grunt.config documentation](api_config.md) for more information about config properties.
+
+_This method is an alias for the [grunt.config.requires](api_config.md) method._
+
+### this.name / grunt.task.current.name <a name="this-name-grunt-task-current-name" href="#this-name-grunt-task-current-name" title="Link to this section">⚑</a>
+The name of the task, as defined in `grunt.registerTask`. For example, if a "sample" task was run as `grunt sample` or `grunt sample:foo`, inside the task function, `this.name` would be `"sample"`.
+
+### this.nameArgs / grunt.task.current.nameArgs <a name="this-nameargs-grunt-task-current-nameargs" href="#this-nameargs-grunt-task-current-nameargs" title="Link to this section">⚑</a>
+The name of the task, as specified with any colon-separated arguments or flags on the command-line. For example, if a "sample" task was run as `grunt sample:foo`, inside the task function, `this.nameArgs` would be `"sample:foo"`.
+
+### this.args / grunt.task.current.args <a name="this-args-grunt-task-current-args" href="#this-args-grunt-task-current-args" title="Link to this section">⚑</a>
+An array of arguments passed to the task. For example, if a "sample" task was run as `grunt sample:foo:bar`, inside the task function, `this.args` would be `["foo", "bar"]`. Note that in multi tasks, the target is removed from the `this.args` array and is not passed into the task function.
+
+### this.flags / grunt.task.current.flags <a name="this-flags-grunt-task-current-flags" href="#this-flags-grunt-task-current-flags" title="Link to this section">⚑</a>
+An object generated from the arguments passed to the task. For example, if a "sample" task was run as `grunt sample:foo:bar`, inside the task function, `this.flags` would be `{foo: true, bar: true}`. In a multi task, the target name is not set as a flag.
+
+### this.errorCount / grunt.task.current.errorCount <a name="this-errorcount-grunt-task-current-errorcount" href="#this-errorcount-grunt-task-current-errorcount" title="Link to this section">⚑</a>
+The number of [grunt.log.error](api_log.md) calls that occurred during this task. This can be used to fail a task if errors occurred during the task.
+
+
+## Inside Multi Tasks <a name="inside-multi-tasks" href="#inside-multi-tasks" title="Link to this section">⚑</a>
+
+### this.target / grunt.task.current.target <a name="this-target-grunt-task-current-target" href="#this-target-grunt-task-current-target" title="Link to this section">⚑</a>
+In a multi task, this is the name of the target currently being iterated over. For example, if a "sample" multi task was run as `grunt sample:foo` with the config data `{sample: {foo: "bar"}}`, inside the task function, `this.target` would be `"foo"`.
+
+### this.data / grunt.task.current.data <a name="this-data-grunt-task-current-data" href="#this-data-grunt-task-current-data" title="Link to this section">⚑</a>
+In a multi task, this is the actual data stored in the grunt config object for the given target. For example, if a "sample" multi task was run as `grunt sample:foo` with the config data `{sample: {foo: "bar"}}`, inside the task function, `this.data` would be `"bar"`.
+
+### this.file / grunt.task.current.file <a name="this-file-grunt-task-current-file" href="#this-file-grunt-task-current-file" title="Link to this section">⚑</a>
+In a multi task, target data can be stored in two different formats. A relatively basic "compact" format and a much more flexible "full" format. When the compact format is used, that key and value are made available as `this.file.dest` and `this.file.src`, respectively. When the full format is used, the specified `src` and `dest` values are used for `this.file.dest` and `this.file.src`.
+
+Note that while grunt supports expanding [templates](api_template.md) for both `src` and `dest`, they only work for the `dest` file path when the _full_ format is used.
+
+```javascript
+grunt.initConfig({
+ concat: {
+ // This is the "compact" format.
+ 'dist/built.js': ['src/file1.js', 'src/file2.js'],
+ // This is the "full" format.
+ built: {
+ src: ['src/file1.js', 'src/file2.js'],
+ dest: 'dist/built.js'
+ }
+ }
+});
+```
+
+
+## Loading Externally-Defined Tasks <a name="loading-externally-defined-tasks" href="#loading-externally-defined-tasks" title="Link to this section">⚑</a>
+For most projects, tasks and helpers will be defined in the [grunt.js gruntfile](getting_started.md). For larger projects, or in cases where tasks and helpers need to be shared across projects, tasks can be loaded from one or more external directories or Npm-installed grunt plugins.
+
+_Note that the methods listed below are also available on the [grunt.task](api_task.md) object in addition to the `grunt` object._
+
+### grunt.loadTasks <a name="grunt-loadtasks" href="#grunt-loadtasks" title="Link to this section">⚑</a>
+Load task-related files from the specified directory, relative to the [grunt.js gruntfile](getting_started.md). This method can be used to load task-related files from a local grunt plugin by specifying the path to that plugin's "tasks" subdirectory.
+
+```javascript
+grunt.loadTasks(tasksPath)
+```
+
+_This method is an alias for the [grunt.task.loadTasks](api_task.md) method._
+
+
+### grunt.loadNpmTasks <a name="grunt-loadnpmtasks" href="#grunt-loadnpmtasks" title="Link to this section">⚑</a>
+Load tasks and helpers from the specified grunt plugin. This plugin must be installed locally via npm, and must be relative to the [grunt.js gruntfile](getting_started.md). Grunt plugins can be created by using the [gruntplugin init template](task_init.md).
+
+```javascript
+grunt.loadNpmTasks(pluginName)
+```
+
+_This method is an alias for the [grunt.task.loadNpmTasks](api_task.md) method._
+
+
+## Defining and Executing Helpers <a name="defining-and-executing-helpers" href="#defining-and-executing-helpers" title="Link to this section">⚑</a>
+Helpers are utility functions that can be used by any task.
+
+For example, in the [min task](../tasks/min.js), the majority of the actual minification work is done in an `uglify` helper, so that other tasks can utilize that minification code if they want to.
+
+See the list of [built-in helpers](helpers_directives.md) for examples.
+
+_Note that the methods listed below are also available on the [grunt.task](api_task.md) object in addition to the `grunt` object._
+
+### grunt.registerHelper <a name="grunt-registerhelper" href="#grunt-registerhelper" title="Link to this section">⚑</a>
+Register a helper function that can be used by any task. When called as a directive, `this.directive` will be true inside of the helper.
+
+```javascript
+grunt.registerHelper(helperName, helperFunction)
+```
+
+In this example helper, the numbers `1` and `2` are passed in and the value `3` is returned.
+
+```javascript
+grunt.registerHelper('add_two_nums', function(a, b) {
+ return a + b;
+});
+```
+
+_This method is an alias for the [grunt.task.registerHelper](api_task.md) method._
+
+### grunt.renameHelper <a name="grunt-renamehelper" href="#grunt-renamehelper" title="Link to this section">⚑</a>
+Rename a helper. This might be useful if you want to override the default behavior of a helper, while retaining the old name (to avoid having to completely recreate an already-made task just because you needed to override or extend a built-in helper).
+
+```javascript
+grunt.renameHelper(oldname, newname)
+```
+
+_This method is an alias for the [grunt.task.renameHelper](api_task.md) method._
+
+### grunt.helper <a name="grunt-helper" href="#grunt-helper" title="Link to this section">⚑</a>
+Invoke a registered helper function.
+
+```javascript
+grunt.helper(helperName [, arguments...])
+```
+
+In this example, the previously defined `add_two_nums` helper is invoked.
+
+```javascript
+grunt.helper('add_two_nums', 1, 2) // 3
+```
+
+_This method is an alias for the [grunt.task.helper](api_task.md) method._
+
+
+## Warnings and Fatal Errors <a name="warnings-and-fatal-errors" href="#warnings-and-fatal-errors" title="Link to this section">⚑</a>
+If something explodes (or is about to explode) inside a helper or task, it can force grunt to abort. See the [exit codes documentation](exit_codes.md) for a list of all built-in grunt exit codes.
+
+### grunt.warn <a name="grunt-warn" href="#grunt-warn" title="Link to this section">⚑</a>
+Display a warning and abort grunt immediately. Grunt will continue processing tasks if the `--force` command-line option was specified. The `error` argument can be a string message or an error object.
+
+```javascript
+grunt.warn(error [, errorcode])
+```
+
+If `--debug 9` is specified on the command-line and an error object was specified, a stack trace will be logged.
+
+_This method is an alias for the [grunt.fail.warn](api_fail.md) method._
+
+### grunt.fatal <a name="grunt-fatal" href="#grunt-fatal" title="Link to this section">⚑</a>
+Display a warning and abort grunt immediately. The `error` argument can be a string message or an error object.
+
+```javascript
+grunt.fail(error [, errorcode])
+```
+
+If `--debug 9` is specified on the command-line and an error object was specified, a stack trace will be logged.
+
+_This method is an alias for the [grunt.fail.fatal](api_fail.md) method._
+
+
+## Command-line Options <a name="command-line-options" href="#command-line-options" title="Link to this section">⚑</a>
+
+### grunt.option <a name="grunt-option" href="#grunt-option" title="Link to this section">⚑</a>
+Retrieve the value of a command-line option, eg. `debug`. Note that for each command-line option, the inverse can be tested, eg. `no-debug`.
+
+```javascript
+grunt.option(optionName)
+```
+
+## Miscellaneous <a name="miscellaneous" href="#miscellaneous" title="Link to this section">⚑</a>
+
+### grunt.version <a name="grunt-version" href="#grunt-version" title="Link to this section">⚑</a>
+The current grunt version, as a string.
+
+```javascript
+grunt.version
+```
+
+### grunt.npmTasks <a name="grunt-npmtasks" href="#grunt-npmtasks" title="Link to this section">⚑</a>
+Inside a [grunt plugin](plugins.md) bin script, this method _must_ be called to inform grunt where to look for that plugin's tasks files. The `npmModuleName` must be the grunt plugin's Npm module name. The [gruntplugin init template](task_init.md), will automatically configure this for you.
+
+```javascript
+grunt.npmTasks(npmModuleName)
+```
+
+## Other Methods <a name="other-methods" href="#other-methods" title="Link to this section">⚑</a>
+
+* [grunt.utils](api_utils.md) - Miscellaneous utilities, including Underscore.js, Async and Hooker.
+* [grunt.template](api_template.md) - Underscore.js template processing and other template-related methods.
+* [grunt.task](api_task.md) - Register and run tasks and helpers, load external tasks.
+* [grunt.file](api_file.md) - Wildcard expansion, file reading, writing, directory traversing.
+* [grunt.config](api_config.md) - Access project-specific configuration data defined in the [grunt.js gruntfile](getting_started.md).
+* [grunt.log](api_log.md), [grunt.verbose](api_log.md) - Output messages to the console.
+* [grunt.fail](api_fail.md) - For when something goes horribly wrong.
94 node_modules/grunt/docs/api_config.md
@@ -0,0 +1,94 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# [The grunt API](api.md) / grunt.config
+
+Access project-specific configuration data defined in the [grunt.js gruntfile](getting_started.md).
+
+See the [config lib source](../lib/grunt/config.js) for more information.
+
+## The config API <a name="the-config-api" href="#the-config-api" title="Link to this section">⚑</a>
+
+Note that any method marked with a ☃ (unicode snowman) is also available directly on the `grunt` object, and any method marked with a ☆ (white star) is also available inside tasks on the `this` object. Just so you know. See the [API main page](api.md) for more usage information.
+
+## Initializing Config Data <a name="initializing-config-data" href="#initializing-config-data" title="Link to this section">⚑</a>
+_Note that the method listed below is also available on the `grunt` object as [grunt.initConfig](api.md)._
+
+### grunt.config.init ☃ <a name="grunt-config-init" href="#grunt-config-init" title="Link to this section">⚑</a>
+Initialize a configuration object for the current project. The specified `configObject` is used by tasks and helpers and can also be accessed using the `grunt.config` method. Nearly every project's [grunt.js gruntfile](getting_started.md) will call this method.
+
+```javascript
+grunt.config.init(configObject)
+```
+
+Note that any specified `<config>` and `<json>` [directives](api_task.md) will be automatically processed when the config object is initialized.
+
+This example contains sample config data for the [lint task](task_lint.md):
+
+```javascript
+grunt.config.init({
+ lint: {
+ all: ['lib/*.js', 'test/*.js', 'grunt.js']
+ }
+});
+```
+
+See the [configuring grunt](getting_started.md) page for more configuration examples.
+
+_This method is also available as [grunt.initConfig](api.md)._
+
+
+## Accessing Config Data <a name="accessing-config-data" href="#accessing-config-data" title="Link to this section">⚑</a>
+The following methods allow grunt configuration data to be accessed either via dot-delimited string like `'pkg.author.name'` or via array of property name parts like `['pkg', 'author', 'name']`.
+
+Note that if a specified property name contains a `.` dot, it must be escaped with a literal backslash, eg. `'concat.dist/built\\.js'`. If an array of parts is specified, grunt will handle the escaping internally with the `grunt.config.escape` method.
+
+### grunt.config <a name="grunt-config" href="#grunt-config" title="Link to this section">⚑</a>
+Get or set a value from the project's grunt configuration. This method serves as an alias to other methods; if two arguments are passed, `grunt.config.set` is called, otherwise `grunt.config.get` is called.
+
+```javascript
+grunt.config([prop [, value]])
+```
+
+### grunt.config.get <a name="grunt-config-get" href="#grunt-config-get" title="Link to this section">⚑</a>
+Get a value from the project's grunt configuration. If `prop` is specified, that property's value is returned, or `null` if that property is not defined. If `prop` isn't specified, a copy of the entire config object is returned.
+
+```javascript
+grunt.config.get([prop])
+```
+
+Any `<% %>` templates in returned values will not be automatically processed, but can be processed afterwards using the [grunt.template.process](api_template.md) method. If you want to do both at once, the `grunt.config.process` method can be used.
+
+### grunt.config.set <a name="grunt-config-set" href="#grunt-config-set" title="Link to this section">⚑</a>
+Set a value into the project's grunt configuration.
+
+```javascript
+grunt.config.set(prop, value)
+```
+
+Note that any specified `<config>` and `<json>` [directives](api_task.md) will be automatically processed when the config data is set.
+
+### grunt.config.escape <a name="grunt-config-escape" href="#grunt-config-escape" title="Link to this section">⚑</a>
+Escape `.` dots in the given `propString`. This should be used for property names that contain dots.
+
+```javascript
+grunt.config.escape(propString)
+```
+
+### grunt.config.process <a name="grunt-config-process" href="#grunt-config-process" title="Link to this section">⚑</a>
+Behaves like `grunt.config.get`, but additionally recursively processes all `<% %>` templates in the returned data.
+
+```javascript
+grunt.config.process([prop])
+```
+
+## Requiring Config Data <a name="requiring-config-data" href="#requiring-config-data" title="Link to this section">⚑</a>
+_Note that the method listed below is also available inside tasks on the `this` object as [this.requiresConfig](api.md)._
+
+### grunt.config.requires ☆ <a name="grunt-config-requires" href="#grunt-config-requires" title="Link to this section">⚑</a>
+Fail the current task if one or more required config properties is missing. One or more string or array config properties may be specified.
+
+```javascript
+grunt.config.requires(prop [, prop [, ...]])
+```
+
+_This method is also available inside tasks as [this.requiresConfig](api.md)._
35 node_modules/grunt/docs/api_fail.md
@@ -0,0 +1,35 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# [The grunt API](api.md) / grunt.fail
+
+For when something goes horribly wrong.
+
+See the [fail lib source](../lib/grunt/fail.js) for more information.
+
+## The fail API <a name="the-fail-api" href="#the-fail-api" title="Link to this section">⚑</a>
+
+If something explodes (or is about to explode) inside a helper or task, it can force grunt to abort. See the [exit codes documentation](exit_codes.md) for a list of all built-in grunt exit codes.
+
+Note that any method marked with a ☃ (unicode snowman) is also available directly on the `grunt` object. Just so you know. See the [API main page](api.md) for more usage information.
+
+### grunt.warn ☃ <a name="grunt-warn" href="#grunt-warn" title="Link to this section">⚑</a>
+Display a warning and abort grunt immediately. Grunt will continue processing tasks if the `--force` command-line option was specified. The `error` argument can be a string message or an error object.
+
+```javascript
+grunt.warn(error [, errorcode])
+```
+
+If `--debug 9` is specified on the command-line and an error object was specified, a stack trace will be logged.
+
+_This method is also available as [grunt.warn](api.md)._
+
+### grunt.fatal ☃ <a name="grunt-fatal" href="#grunt-fatal" title="Link to this section">⚑</a>
+Display a warning and abort grunt immediately. The `error` argument can be a string message or an error object.
+
+```javascript
+grunt.fail(error [, errorcode])
+```
+
+If `--debug 9` is specified on the command-line and an error object was specified, a stack trace will be logged.
+
+_This method is also available as [grunt.fatal](api.md)._
184 node_modules/grunt/docs/api_file.md
@@ -0,0 +1,184 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# [The grunt API](api.md) / grunt.file
+
+Wildcard expansion, file reading, writing, directory traversing.
+
+See the [file lib source](../lib/grunt/file.js) for more information.
+
+## The file API <a name="the-file-api" href="#the-file-api" title="Link to this section">⚑</a>
+There are many provided methods for reading and writing files, as well as traversing the filesystem and finding files by wildcard patterns. Many of these methods are wrappers around core Node.js file functionality, but with additional error handling and logging.
+
+_Note: all file paths are relative to the [grunt.js gruntfile](getting_started.md) unless the current working directory is changed with `grunt.file.setBase` or the `--base` command-line option._
+
+### grunt.file.read <a name="grunt-file-read" href="#grunt-file-read" title="Link to this section">⚑</a>
+Read and return a file's contents. The `encoding` argument defaults to `utf8` if unspecified.
+
+```javascript
+grunt.file.read(filepath, encoding)
+```
+
+### grunt.file.readJSON <a name="grunt-file-readjson" href="#grunt-file-readjson" title="Link to this section">⚑</a>
+Read a file's contents, parsing the data as JSON and returning the result.
+
+```javascript
+grunt.file.readJSON(filepath)
+```
+
+### grunt.file.write <a name="grunt-file-write" href="#grunt-file-write" title="Link to this section">⚑</a>
+Write the specified contents to a file, creating intermediate directories if necessary.
+
+_If the `--no-write` command-line option is specified, the file won't actually be written._
+
+```javascript
+grunt.file.write(filepath, contents)
+```
+
+### grunt.file.copy <a name="grunt-file-copy" href="#grunt-file-copy" title="Link to this section">⚑</a>
+Copy a source file to a destination path, creating intermediate directories if necessary.
+
+_If the `--no-write` command-line option is specified, the file won't actually be written._
+
+```javascript
+grunt.file.copy(srcpath, destpath [, options])
+```
+
+The `options` object has these possible properties:
+
+```javascript
+var options = {
+ // If specified, the file contents will be parsed as `utf8` and passed into
+ // the function, whose return value will be used as the destination file's
+ // contents. If this function returns false, the file copy will be aborted.
+ process: processFunction,
+ // These optional wildcard patterns will be matched against the filepath using
+ // grunt.file.isMatch. If a specified wildcard pattern matches, the file will
+ // not be processed via `processFunction`. Note that `true` may also be
+ // specified to prvent processing.
+ noProcess: wildcardPatterns
+};
+```
+
+### grunt.file.mkdir <a name="grunt-file-mkdir" href="#grunt-file-mkdir" title="Link to this section">⚑</a>
+Works like `mkdir -p`. Create a directory along with any intermediate directories.
+
+_If the `--no-write` command-line option is specified, directories won't actually be created._
+
+```javascript
+grunt.file.mkdir(dirpath)
+```
+
+### grunt.file.recurse <a name="grunt-file-recurse" href="#grunt-file-recurse" title="Link to this section">⚑</a>
+Recurse into a directory, executing `callback` for each file.
+
+```javascript
+grunt.file.recurse(rootdir, callback)
+```
+
+The callback function receives the following arguments:
+
+```javascript
+function callback(abspath, rootdir, subdir, filename) {
+ // The full path to the current file, which is nothing more than
+ // the rootdir + subdir + filename arguments, joined.
+ abspath
+ // The root director, as originally specified.
+ rootdir
+ // The current file's directory, relative to rootdir.
+ subdir
+ // The filename of the current file, without any directory parts.
+ filename
+}
+```
+
+### grunt.file.findup <a name="grunt-file-findup" href="#grunt-file-findup" title="Link to this section">⚑</a>
+Search for a filename in the given directory followed by all parent directories. Returns the first matching filepath found, otherwise returns `null`.
+
+```javascript
+grunt.file.findup(rootdir, filename)
+```
+
+### grunt.file.isPathAbsolute <a name="grunt-file-ispathabsolute" href="#grunt-file-ispathabsolute" title="Link to this section">⚑</a>
+Is a given file path absolute? Returns a boolean.
+
+Like the Node.js [path.join](http://nodejs.org/docs/latest/api/path.html#path_path_join_path1_path2) method, this method will join all arguments together and normalize the resulting path.
+
+```javascript
+grunt.file.isPathAbsolute(path1 [, path2 [, ...]])
+```
+
+### grunt.file.userDir <a name="grunt-file-userdir" href="#grunt-file-userdir" title="Link to this section">⚑</a>
+Return a file path relative to the user's `.grunt` directory, which is `%USERPROFILE%\.grunt\` on Windows, and `~/.grunt/` on OS X or Linux. If no file path is specified, the base user `.grunt` directory path will be returned. If the specified path is not found, `null` is returned.
+
+Windows users: `%USERPROFILE%` is generally your `Documents and Settings` directory.
+
+_Like the Node.js [path.join](http://nodejs.org/docs/latest/api/path.html#path_path_join_path1_path2) method, this method will join all arguments together and normalize the resulting path._
+
+```javascript
+grunt.file.userDir([path1, [, path2 [, ...]]])
+```
+
+### grunt.file.setBase <a name="grunt-file-setbase" href="#grunt-file-setbase" title="Link to this section">⚑</a>
+Change grunt's current working directory. By default, all file paths are relative to the [grunt.js gruntfile](getting_started.md). This works just like the `--base` command-line option.
+
+```javascript
+grunt.file.setBase(path1 [, path2 [, ...]])
+```
+
+Like the Node.js [path.join](http://nodejs.org/docs/latest/api/path.html#path_path_join_path1_path2) method, this method will join all arguments together and normalize the resulting path.
+
+
+## File Lists and Wildcards <a name="file-lists-and-wildcards" href="#file-lists-and-wildcards" title="Link to this section">⚑</a>
+Wildcard patterns are resolved using the [glob-whatev library](https://github.com/cowboy/node-glob-whatev). See the [minimatch](https://github.com/isaacs/minimatch) module documentation for more details on supported wildcard patterns.
+
+There are also a number of [task-specific file listing methods](api_task.md) that find files inside grunt plugins and task directories.
+
+_Note: all file paths are relative to the [grunt.js gruntfile](getting_started.md) unless the current working directory is changed with `grunt.file.setBase` or the `--base` command-line option._
+
+### grunt.file.expand <a name="grunt-file-expand" href="#grunt-file-expand" title="Link to this section">⚑</a>
+Return a unique array of all file or directory paths that match the given wildcard pattern(s). This method accepts one or more comma separated wildcard patterns as well as an array of wildcard patterns.
+
+The `options` object supports all [minimatch](https://github.com/isaacs/minimatch) options.
+
+```javascript
+grunt.file.expand([options, ] patterns)
+```
+
+### grunt.file.expandDirs <a name="grunt-file-expanddirs" href="#grunt-file-expanddirs" title="Link to this section">⚑</a>
+This method behaves the same as `grunt.file.expand` except it only returns directory paths.
+
+```javascript
+grunt.file.expandDirs([options, ] patterns)
+```
+
+### grunt.file.expandFiles <a name="grunt-file-expandfiles" href="#grunt-file-expandfiles" title="Link to this section">⚑</a>
+This method behaves the same as `grunt.file.expand` except it only returns file paths.
+
+```javascript
+grunt.file.expandFiles([options, ] patterns)
+```
+
+This method is used by many built-in tasks to handle wildcard expansion of the specified source files. See the [concat task source](../tasks/concat.js) for an example.
+
+### grunt.file.expandFileURLs <a name="grunt-file-expandfileurls" href="#grunt-file-expandfileurls" title="Link to this section">⚑</a>
+Return a unique array of all `file://` URLs for files that match the given wildcard pattern(s). Any absolute `file://`, `http://` or `https://` URLs specified will be passed through. This method accepts one or more comma separated wildcard patterns (or URLs), as well as an array of wildcard patterns (or URLs).
+
+```javascript
+grunt.file.expandFileURLs(patternsOrURLs)
+```
+
+See the [qunit task source](../tasks/qunit.js) for an example.
+
+### grunt.file.isMatch <a name="grunt-file-ismatch" href="#grunt-file-ismatch" title="Link to this section">⚑</a>
+Match one or more wildcard patterns against a file path. If any of the specified matches, return `true` otherwise return `false`. This method accepts a single string wildcard pattern as well as an array of wildcard patterns. Note that `true` may also be specified to prvent processing.
+
+```javascript
+grunt.file.isMatch(patterns, filepath)
+```
+
+Patterns without slashes will be matched against the basename of the path if it contains slashes, eg. pattern `*.js` will match filepath `path/to/file.js`.
+
+## External libraries <a name="external-libraries" href="#external-libraries" title="Link to this section">⚑</a>
+
+### grunt.file.glob <a name="grunt-file-glob" href="#grunt-file-glob" title="Link to this section">⚑</a>
+[glob-whatev](https://github.com/cowboy/node-glob-whatev) - Synchronous file globbing utility.
144 node_modules/grunt/docs/api_log.md
@@ -0,0 +1,144 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# [The grunt API](api.md) / grunt.log, grunt.verbose
+
+Output messages to the console.
+
+See the [log lib source](../lib/grunt/log.js) for more information.
+
+## The log API <a name="the-log-api" href="#the-log-api" title="Link to this section">⚑</a>
+Grunt output should look consistent, and maybe even pretty. As such, there is a plethora of logging methods, and a few useful patterns. All of the methods that actually log something are chainable.
+
+_Note: all methods available under `grunt.verbose` work exactly like `grunt.log` methods, but only log if the `--verbose` command-line option was specified._
+
+### grunt.log.write / grunt.verbose.write <a name="grunt-log-write-grunt-verbose-write" href="#grunt-log-write-grunt-verbose-write" title="Link to this section">⚑</a>
+Log the specified `msg` string, with no trailing newline.
+
+```javascript
+grunt.log.write(msg)
+```
+
+### grunt.log.writeln / grunt.verbose.writeln <a name="grunt-log-writeln-grunt-verbose-writeln" href="#grunt-log-writeln-grunt-verbose-writeln" title="Link to this section">⚑</a>
+Log the specified `msg` string, with trailing newline.
+
+```javascript
+grunt.log.writeln([msg])
+```
+
+### grunt.log.error / grunt.verbose.error <a name="grunt-log-error-grunt-verbose-error" href="#grunt-log-error-grunt-verbose-error" title="Link to this section">⚑</a>
+If `msg` string is omitted, logs `ERROR` in red, otherwise logs `>> msg`, with trailing newline.
+
+```javascript
+grunt.log.error([msg])
+```
+
+### grunt.log.ok / grunt.verbose.ok <a name="grunt-log-ok-grunt-verbose-ok" href="#grunt-log-ok-grunt-verbose-ok" title="Link to this section">⚑</a>
+If `msg` string is omitted, logs `OK` in green, otherwise logs `>> msg`, with trailing newline.
+
+```javascript
+grunt.log.ok([msg])
+```
+
+### grunt.log.subhead / grunt.verbose.subhead <a name="grunt-log-subhead-grunt-verbose-subhead" href="#grunt-log-subhead-grunt-verbose-subhead" title="Link to this section">⚑</a>
+Log the specified `msg` string in **bold**, with trailing newline.
+
+```javascript
+grunt.log.subhead(msg)
+```
+
+### grunt.log.writeflags / grunt.verbose.writeflags <a name="grunt-log-writeflags-grunt-verbose-writeflags" href="#grunt-log-writeflags-grunt-verbose-writeflags" title="Link to this section">⚑</a>
+Log a list of `obj` properties (good for debugging flags).
+
+```javascript
+grunt.log.writeflags(obj, prefix)
+```
+
+### grunt.log.debug / grunt.verbose.debug <a name="grunt-log-debug-grunt-verbose-debug" href="#grunt-log-debug-grunt-verbose-debug" title="Link to this section">⚑</a>
+Logs a debugging message, but only if the `--debug` command-line option was specified.
+
+```javascript
+grunt.log.debug(msg)
+```
+
+## Verbose and Notverbose <a name="verbose-and-notverbose" href="#verbose-and-notverbose" title="Link to this section">⚑</a>
+All logging methods available under `grunt.verbose` work exactly like their `grunt.log` counterparts, but only log if the `--verbose` command-line option was specified. There is also a "notverbose" counterpart available at both `grunt.log.notverbose` and `grunt.log.verbose.or`. In fact, the `.or` property can be used on both `verbose` and `notverbose` to effectively toggle between the two.
+
+### grunt.verbose / grunt.log.verbose <a name="grunt-verbose-grunt-log-verbose" href="#grunt-verbose-grunt-log-verbose" title="Link to this section">⚑</a>
+This object contains all methods of `grunt.log` but only logs if the `--verbose` command-line option was specified.
+
+```javascript
+grunt.verbose
+```
+
+### grunt.verbose.or / grunt.log.notverbose <a name="grunt-verbose-or-grunt-log-notverbose" href="#grunt-verbose-or-grunt-log-notverbose" title="Link to this section">⚑</a>
+This object contains all methods of `grunt.log` but only logs if the `--verbose` command-line option was _not_ specified.
+
+```javascript
+grunt.verbose.or
+```
+
+## Utility Methods <a name="utility-methods" href="#utility-methods" title="Link to this section">⚑</a>
+These methods don't actually log, they just return strings that can be used in other methods.
+
+### grunt.log.wordlist <a name="grunt-log-wordlist" href="#grunt-log-wordlist" title="Link to this section">⚑</a>
+Returns a comma-separated list of `arr` array items.
+
+```javascript
+grunt.log.wordlist(arr)
+```
+
+### grunt.log.uncolor <a name="grunt-log-uncolor" href="#grunt-log-uncolor" title="Link to this section">⚑</a>
+Removes all color information from a string, making it suitable for testing `.length` or perhaps logging to a file.
+
+```javascript
+grunt.log.uncolor(str)
+```
+
+### grunt.log.wraptext <a name="grunt-log-wraptext" href="#grunt-log-wraptext" title="Link to this section">⚑</a>
+Wrap `text` string to `width` characters with `\n`, ensuring that words are not split in the middle unless absolutely necessary.
+
+```javascript
+grunt.log.wraptext(width, text)
+```
+
+### grunt.log.table <a name="grunt-log-table" href="#grunt-log-table" title="Link to this section">⚑</a>
+Wrap `texts` array of strings to columns `widths` characters wide. A wrapper for the `grunt.log.wraptext` method that can be used to generate output in columns.
+
+```javascript
+grunt.log.table(widths, texts)
+```
+
+
+## An Example <a name="an-example" href="#an-example" title="Link to this section">⚑</a>
+
+A common pattern is to only log when in `--verbose` mode OR if an error occurs, like so:
+
+```javascript
+grunt.registerHelper('something', function(arg) {
+ var result;
+ var msg = 'Doing something...';
+ grunt.verbose.write(msg);
+ try {
+ result = doSomethingThatThrowsAnExceptionOnError(arg);
+ // Success!
+ grunt.verbose.ok();
+ return result;
+ } catch(e) {
+ // Something went wrong.
+ grunt.verbose.or.write(msg).error().error(e.message);
+ grunt.fail.warn('Something went wrong.', 50);
+ }
+});
+```
+
+An explanation of the above code:
+
+1. `grunt.verbose.write(msg);` logs the message (no newline), but only in `--verbose` mode.
+2. `grunt.verbose.ok();` logs OK in green, with a newline.
+3. `grunt.verbose.or.write(msg).error().error(e.message);` does a few things:
+ 1. `grunt.verbose.or.write(msg)` logs the message (no newline) if not in `--verbose` mode, and returns the `notverbose` object.
+ 2. `.error()` logs ERROR in red, with a newline, and returns the `notverbose` object.
+ 3. `.error(e.message);` logs the actual error message (and returns the `notverbose` object).
+4. `grunt.fail.warn('Something went wrong.', 50);` logs a warning in bright yellow, exiting grunt with exit code 50, unless `--force` was specified.
+
+Take a look at the [built-in tasks source code](../tasks) for more examples.
416 node_modules/grunt/docs/api_task.md
@@ -0,0 +1,416 @@
+[Grunt homepage](https://github.com/cowboy/grunt) | [Documentation table of contents](toc.md)
+
+# [The grunt API](api.md) / grunt.task
+
+Register and run tasks and helpers, load external tasks.
+
+See the [task lib source](../lib/grunt/task.js) and [task util lib source](../lib/util/task.js) for more information.
+
+## The task API <a name="the-task-api" href="#the-task-api" title="Link to this section">⚑</a>
+
+Note that any method marked with a ☃ (unicode snowman) is also available directly on the `grunt` object. Just so you know. See the [API main page](api.md) for more usage information.
+
+
+## Creating Tasks <a name="creating-tasks" href="#creating-tasks" title="Link to this section">⚑</a>
+Tasks are grunt's bread and butter. The stuff you do most often, like `lint` or `test`. Every time grunt is run, you specify one more more tasks to run, which tells grunt what you'd like it to do.
+
+If you don't specify a task, but a task named "default" has been defined, that task will run (unsurprisingly) by default.
+
+### grunt.task.registerTask ☃ <a name="grunt-task-registertask" href="#grunt-task-registertask" title="Link to this section">⚑</a>
+Register an "alias task" or a task function. This method supports the following two signatures:
+
+**Alias task**
+
+If a task list is specified, the new task will be an alias for one or more other tasks. Whenever this "alias task" is run, every specified task in `taskList` will be run, in the order specified. The `taskList` argument can be a space-separated string or an array of task names.
+
+```javascript
+grunt.task.registerTask(taskName, taskList)
+```
+
+This example alias task defines a "default" task whereby the "lint", "qunit", "concat" and "min" tasks are run automatically if grunt is executed without any tasks specified:
+
+```javascript
+task.registerTask('default', 'lint qunit concat min');
+```
+
+**Function task**
+
+If a `description` and `taskFunction` are passed, the specified function will be executed whenever the task is run. In addition, the specified description will be shown when `grunt --help` is run. Task-specific properties and methods are available inside the task function as properties of the `this` object. The task function can return `false` to indicate that the task has failed.
+
+Note that the `grunt.task.registerMultiTask` method, explained below, can be used to define a special type of task known as a "multi task."
+
+```javascript
+grunt.task.registerTask(taskName, description, taskFunction)
+```
+
+This example task logs `foo, testing 123` if grunt is run via `grunt foo:testing:123`. If the task is run without arguments as `grunt foo` the task logs `foo, no args`.
+
+```javascript
+grunt.task.registerTask('foo', 'A sample task that logs stuff.', function(arg1, arg2) {
+ if (arguments.length === 0) {
+ grunt.log.writeln(this.name + ", no args");
+ } else {
+ grunt.log.writeln(this.name + ", " + arg1 + " " + arg2);
+ }
+});
+```
+
+See the [creating tasks](types_of_tasks.md) documentation for more examples of tasks and alias tasks.
+
+_This method is also available as [grunt.registerTask](api.md)._
+
+
+### grunt.task.registerMultiTask ☃ <a name="grunt-task-registermultitask" href="#grunt-task-registermultitask" title="Link to this section">⚑</a>
+Register a "multi task." A multi task is a task that implicitly iterates over all of its named sub-properties (AKA targets) if no target was specified. In addition to the default properties and methods, extra multi task-specific properties are available inside the task function as properties of the `this` object.
+
+Many of the built-in tasks, including the [lint task](task_lint.md), [concat task](task_concat.md) and [min task](task_min.md) are multi tasks.
+
+```javascript
+grunt.task.registerMultiTask(taskName, description, taskFunction)
+```
+
+Given the specified configuration, this example multi task would log `foo: 1,2,3` if grunt was run via `grunt log:foo`, or it would log `bar: hello world` if grunt was run via `grunt log:bar`. If grunt was run as `grunt log` however, it would log `foo: 1,2,3` then `bar: hello world` then `baz: false`.
+
+```javascript
+grunt.initConfig({
+ log: {
+ foo: [1, 2, 3],
+ bar: 'hello world',
+ baz: false
+ }
+});
+
+grunt.task.registerMultiTask('log', 'Log stuff.', function() {
+ grunt.log.writeln(this.target + ': ' + this.data);
+});
+```
+
+See the [creating tasks](types_of_tasks.md) documentation for more examples of multi tasks.
+
+_This method is also available as [grunt.registerMultiTask](api.md)._
+
+
+### grunt.task.registerInitTask ☃ <a name="grunt-task-registerinittask" href="#grunt-task-registerinittask" title="Link to this section">⚑</a>
+Register an "init task." An init task is a task that doesn't require any configuration data, and as such will still run even if grunt can't find a [grunt.js gruntfile](getting_started.md). The included [init task](task_init.md) is an example of an "init task."
+
+```javascript
+grunt.task.registerInitTask(taskName, description, taskFunction)
+```
+
+For an init task example, see the [init task source](../tasks/init.js).
+
+_This method is also available as [grunt.registerInitTask](api.md)._
+
+### grunt.task.renameTask ☃ <a name="grunt-task-renametask" href="#grunt-task-renametask" title="Link to this section">⚑</a>
+Rename a task. This might be useful if you want to override the default behavior of a task, while retaining the old name.
+
+```javascript
+grunt.task.renameTask(oldname, newname)
+```
+
+_This method is also available as [grunt.renameTask](api.md)._
+
+## Inside Tasks <a name="inside-tasks" href="#inside-tasks" title="Link to this section">⚑</a>
+An object is made available as `this` inside each task function that contains a number of useful task-specific properties and methods. This same object is also exposed as `grunt.task.current` for use in [templates](api_template.md).
+
+### this.async / grunt.task.current.async <a name="this-async-grunt-task-current-async" href="#this-async-grunt-task-current-async" title="Link to this section">⚑</a>
+If a task is asynchronous, this method must be invoked to instruct grunt to wait. It returns a handle to a "done" function that should be called when the task has completed. `false` can be passed to the done function to indicate that the task has failed. If this method isn't invoked, the task executes synchronously.
+
+```javascript
+// Tell grunt this task is asynchronous.
+var done = this.async();
+// Your async code.
+setTimeout(function() {
+ // Let's simulate an error, sometimes.
+ var success = Math.random() > 0.5;
+ // All done!
+ done(success);
+}, 1000);
+```
+
+### this.requires / grunt.task.current.requires <a name="this-requires-grunt-task-current-requires" href="#this-requires-grunt-task-current-requires" title="Link to this section">⚑</a>
+If one task depends on the successful completion of another task (or tasks), this method can be used to force grunt to abort if the other task didn't run, or if the other task failed. The task list can be a space-separated string, an array of task names, or individual task name arguments.
+
+Note that this won't actually run the specified task(s), it will just fail the current task if they haven't already run successfully.
+
+```javascript
+this.requires(taskList)
+```
+
+### this.requiresConfig / grunt.task.current.requiresConfig <a name="this-requiresconfig-grunt-task-current-requiresconfig" href="#this-requiresconfig-grunt-task-current-requiresconfig" title="Link to this section">⚑</a>
+Fail the current task if one or more required [config](api_config.md) properties is missing. One or more string or array config properties may be specified.
+
+```javascript
+this.requiresConfig(prop [, prop [, ...]])
+```
+
+See the [grunt.config documentation](api_config.md) for more information about config properties.
+
+_This method is an alias for the [grunt.config.requires](api_config.md) method._
+
+### this.name / grunt.task.current.name <a name="this-name-grunt-task-current-name" href="#this-name-grunt-task-current-name" title="Link to this section">⚑</a>
+The name of the task, as defined in `grunt.registerTask`. For example, if a "sample" task was run as `grunt sample` or `grunt sample:foo`, inside the task function, `this.name` would be `"sample"`.
+
+### this.nameArgs / grunt.task.current.nameArgs <a name="this-nameargs-grunt-task-current-nameargs" href="#this-nameargs-grunt-task-current-nameargs" title="Link to this section">⚑</a>
+The name of the task, as specified with any colon-separated arguments or flags on the command-line. For example, if a "sample" task was run as `grunt sample:foo`, inside the task function, `this.nameArgs` would be `"sample:foo"`.
+
+### this.args / grunt.task.current.args <a name="this-args-grunt-task-current-args" href="#this-args-grunt-task-current-args" title="Link to this section">⚑</a>
+An array of arguments passed to the task. For example, if a "sample" task was run as `grunt sample:foo:bar`, inside the task function, `this.args` would be `["foo", "bar"]`. Note that in multi tasks, the target is removed from the `this.args` array and is not passed into the task function.
+
+### this.flags / grunt.task.current.flags <a name="this-flags-grunt-task-current-flags" href="#this-flags-grunt-task-current-flags" title="Link to this section">⚑</a>
+An object generated from the arguments passed to the task. For example, if a "sample" task was run as `grunt sample:foo:bar`, inside the task function, `this.flags` would be `{foo: true, bar: true}`. In a multi task, the target name is not set as a flag.
+
+### this.errorCount / grunt.task.current.errorCount <a name="this-errorcount-grunt-task-current-errorcount" href="#this-errorcount-grunt-task-current-errorcount" title="Link to this section">⚑</a>
+The number of [grunt.log.error](api_log.md) calls that occurred during this task. This can be used to fail a task if errors occurred during the task.
+
+
+## Inside Multi Tasks <a name="inside-multi-tasks" href="#inside-multi-tasks" title="Link to this section">⚑</a>
+
+### this.target / grunt.task.current.target <a name="this-target-grunt-task-current-target" href="#this-target-grunt-task-current-target" title="Link to this section">⚑</a>
+In a multi task, this is the name of the target currently being iterated over. For example, if a "sample" multi task was run as `grunt sample:foo` with the config data `{sample: {foo: "bar"}}`, inside the task function, `this.target` would be `"foo"`.
+
+### this.data / grunt.task.current.data <a name="this-data-grunt-task-current-data" href="#this-data-grunt-task-current-data" title="Link to this section">⚑</a>
+In a multi task, this is the actual data stored in the grunt config object for the given target. For example, if a "sample" multi task was run as `grunt sample:foo` with the config data `{sample: {foo: "bar"}}`, inside the task function, `this.data` would be `"bar"`.
+
+### this.file / grunt.task.current.file <a name="this-file-grunt-task-current-file" href="#this-file-grunt-task-current-file" title="Link to this section">⚑</a>
+In a multi task, target data can be stored in two different formats. A relatively basic "compact" format and a much more flexible "full" format. When the compact format is used, that key and value are made available as `this.file.dest` and `this.file.src`, respectively. When the full format is used, the specified `src` and `dest` values are used for `this.file.dest` and `this.file.src`.
+
+Note that while grunt supports expanding [templates](api_template.md) for both `src` and `dest`, they only work for the `dest` file path when the _full_ format is used.
+
+```javascript
+grunt.initConfig({
+ concat: {
+ // This is the "compact" format.
+ 'dist/built.js': ['src/file1.js', 'src/file2.js'],
+ // This is the "full" format.
+ built: {
+ src: ['src/file1.js', 'src/file2.js'],
+ dest: 'dist/built.js'
+ }
+ }
+});
+```
+
+
+## Loading Externally-Defined Tasks <a name="loading-externally-defined-tasks" href="#loading-externally-defined-tasks" title="Link to this section">⚑</a>
+For most projects, tasks and helpers will be defined in the [grunt.js gruntfile](getting_started.md). For larger projects, or in cases where tasks and helpers need to be shared across projects, tasks can be loaded from one or more external directories or Npm-installed grunt plugins.
+
+### grunt.task.loadTasks ☃ <a name="grunt-task-loadtasks" href="#grunt-task-loadtasks" title="Link to this section">⚑</a>
+Load task-related files from the specified directory, relative to the [grunt.js gruntfile](getting_started.md). This method can be used to load task-related files from a local grunt plugin by specifying the path to that plugin's "tasks" subdirectory.
+
+```javascript
+grunt.task.loadTasks(tasksPath)
+```
+
+_This method is also available as [grunt.loadTasks](api.md)._
+
+
+### grunt.task.loadNpmTasks ☃ <a name="grunt-task-loadnpmtasks" href="#grunt-task-loadnpmtasks" title="Link to this section">⚑</a>
+Load tasks and helpers from the specified grunt plugin. This plugin must be installed locally via npm, and must be relative to the [grunt.js gruntfile](getting_started.md). Grunt plugins can be created by using the [gruntplugin init template](task_init.md).
+
+```javascript
+grunt.task.loadNpmTasks(pluginName)
+```
+
+_This method is also available as [grunt.loadNpmTasks](api.md)._
+
+
+## Helpers <a name="helpers" href="#helpers" title="Link to this section">⚑</a>
+Helpers are utility functions that can be used by any task.
+
+For example, in the [min task](../tasks/min.js), the majority of the actual minification work is done in an `uglify` helper, so that other tasks can utilize that minification code if they want to.
+
+See the list of [built-in helpers](helpers_directives.md) for examples.
+
+### grunt.task.registerHelper ☃ <a name="grunt-task-registerhelper" href="#grunt-task-registerhelper" title="Link to this section">⚑</a>
+Register a helper function that can be used by any task. When called as a directive, `this.directive` will be true inside of the helper.
+
+```javascript
+grunt.task.registerHelper(helperName, helperFunction)
+```
+
+In this example helper, the numbers `1` and `2` are passed in and the value `3` is returned.
+
+```javascript
+grunt.task.registerHelper("add_two_nums", function(a, b) {
+ return a + b;
+});
+```
+
+_This method is also available as [grunt.registerHelper](api.md)._
+
+### grunt.task.renameHelper ☃ <a name="grunt-task-renamehelper" href="#grunt-task-renamehelper" title="Link to this section">⚑</a>
+Rename a helper. This might be useful if you want to override the default behavior of a helper, while retaining the old name (to avoid having to completely recreate an already-made task just because you needed to override or extend a built-in helper).
+
+```javascript
+grunt.task.renameHelper(oldname, newname)
+```
+
+_This method is also available as [grunt.renameHelper](api.md)._
+
+### grunt.task.helper ☃ <a name="grunt-task-helper" href="#grunt-task-helper" title="Link to this section">⚑</a>
+Invoke a registered helper function.
+
+```javascript
+grunt.task.helper(helperName [, arguments...])
+```
+
+In this example, the previously defined `add_two_nums` helper is invoked.
+
+```javascript
+grunt.task.helper("add_two_nums", 1, 2) // 3
+```
+
+_This method is also available as [grunt.helper](api.md)._
+
+## Directives <a name="directives" href="#directives" title="Link to this section">⚑</a>
+Directives are essentially string placeholders for helper functions, specified as values in the [config object](getting_started.md).
+
+A good example of directives would be the `<json:package.json>` and `<config:lint.all>` directives in grunt's own [grunt.js gruntfile](../grunt.js). Or the `<banner>` and `<file_strip_banner:src/grunt-jquery-example.js>` directives in the [sample jQuery plugin gruntfile](https://github.com/cowboy/grunt-jquery-example/blob/master/grunt.js).
+
+See the list of [built-in directives](helpers_directives.md) for examples.
+
+### grunt.task.directive <a name="grunt-task-directive" href="#grunt-task-directive" title="Link to this section">⚑</a>
+Manually execute a helper based on the passed string directive, returning its value. Note that this only works for synchronous helpers. When called as a directive, `this.directive` will be true inside of the helper.
+
+```javascript
+grunt.task.directive(directive)
+```
+
+In this example, note that the arguments passed into the helper must be coerced into numbers because all directive arguments are passed into the helper as strings.
+
+```javascript
+grunt.task.registerHelper('add_two_numbers', function(a, b) {
+ return Number(a) + Number(b);
+});
+
+grunt.task.directive('<add_two_numbers:1:2>') // 3
+```
+
+### grunt.task.getDirectiveParts <a name="grunt-task-getdirectiveparts" href="#grunt-task-getdirectiveparts" title="Link to this section">⚑</a>
+Split a valid directive into its components. Returns `null` if the string can't be parsed as a directive or if the directive doesn't match an existing helper.
+
+```javascript
+grunt.task.getDirectiveParts(directive)
+```
+
+In this example, the directive can't be parsed initially because the appropriate helper hasn't been defined. Once the helper has been defined, the directive can be parsed.
+
+```javascript
+grunt.task.getDirectiveParts('<foo:bar:baz>') // null
+
+grunt.task.registerHelper('foo', function() {});
+grunt.task.getDirectiveParts('<foo:bar:baz>') // ['foo', 'bar', 'baz']
+```
+
+
+## Queueing Tasks <a name="queueing-tasks" href="#queueing-tasks" title="Link to this section">⚑</a>
+Grunt automatically enqueues and runs all tasks specified on the command line, but individual tasks can enqueue additional tasks to be run.
+
+### grunt.task.run <a name="grunt-task-run" href="#grunt-task-run" title="Link to this section">⚑</a>
+Enqueue one or more tasks. Every specified task in `taskList` will be run immediately after the current task completes, in the order specified. The task list can be a space-separated string, an array of task names, or individual task name arguments.
+
+```javascript
+grunt.task.run(taskList)
+```
+
+See the [watch task source](../tasks/watch.js) for an example.
+
+### grunt.task.clearQueue <a name="grunt-task-clearqueue" href="#grunt-task-clearqueue" title="Link to this section">⚑</a>
+Empty the task queue completely. Unless additional tasks are enqueued, no more tasks will be run.
+
+```javascript
+grunt.task.clearQueue()
+```
+
+See the [watch task source](../tasks/watch.js) for an example.
+
+
+## Search Directories <a name="search-directories" href="#search-directories" title="Link to this section">⚑</a>
+For a given tasks file or related task "extra" file, these paths will be searched in this order, aka "task path order," until the first matching file is found.
+
+1. The grunt user tasks directory, ie. `grunt.file.userDir('tasks')`.
+2. Npm-installed [grunt plugins](plugins.md) or tasks directories specified on the command-line via the `--tasks` option.
+3. Npm-installed grunt plugins, tasks directories or individual tasks and helpers specified in the [grunt.js gruntfile](getting_started.md).
+4. Task directories built-in to a Npm-installed grunt plugin run via its `grunt-` named binary.
+5. The [built-in grunt tasks directory](../tasks).
+
+This allows referenced Npm-installed grunt plugins, tasks directories, the [grunt.js gruntfile](getting_started.md) and even the user to override grunt functionality as needed.
+
+For example, a grunt plugin may add a new "foo" task in its `tasks/foo.js`, completely override an existing task like the [concat task](task_concat.md) in its `tasks/concat.js` or add a new "bar" [init task](task_init.md) template with its `tasks/init/bar.js` and "extra" files in its `tasks/init/bar/` directory. In your personal user tasks directory, you can create your own "baz" init task template with a `tasks/init/baz.js` file or even override individual init template "extra" files like `tasks/init/jquery/root/README.md` just by creating them.
+
+**When defining project-specific tasks or "extra" files, it's always a good idea to include those files in a grunt plugin or tasks directory referenced in the [grunt.js gruntfile](getting_started.md), and committed with the project when possible. This will help to guarantee consistent grunt behavior for all contributors to that project.**
+
+### grunt.task.searchDirs <a name="grunt-task-searchdirs" href="#grunt-task-searchdirs" title="Link to this section">⚑</a>
+An array of directory paths that grunt uses to search for task-related files, in "task path order." This array is used by all task-specific file listing methods.
+
+```javascript
+grunt.task.searchDirs
+```
+
+
+## File Lists and Wildcards <a name="file-lists-and-wildcards" href="#file-lists-and-wildcards" title="Link to this section">⚑</a>
+Wildcard patterns are resolved using the [glob-whatev library](https://github.com/cowboy/node-glob-whatev). See the [minimatch](https://github.com/isaacs/minimatch) module documentation for more details on supported wildcard patterns.
+
+There are also a number of [generic file listing methods](api_file.md) that list files relative to the [grunt.js gruntfile](getting_started.md).