embeditor-rails 1.1.1 → 2.0.0.beta

Sign up to get free protection for your applications and to get access to all the features.
Files changed (1029) hide show
  1. data/README.md +25 -17
  2. data/app/assets/javascripts/embeditor/adapter.js.coffee +21 -2
  3. data/app/assets/javascripts/embeditor/adapters/embedly.js.coffee +4 -40
  4. data/app/assets/javascripts/embeditor/adapters/oembed.js.coffee +37 -2
  5. data/app/assets/javascripts/embeditor/embeditor.js.coffee +16 -4
  6. data/lib/embeditor-rails/version.rb +1 -1
  7. data/lib/node_modules/npm/AUTHORS +158 -0
  8. data/lib/node_modules/npm/CONTRIBUTING.md +9 -0
  9. data/lib/node_modules/npm/LICENSE +235 -0
  10. data/lib/node_modules/npm/Makefile +216 -0
  11. data/lib/node_modules/npm/README.md +241 -0
  12. data/lib/node_modules/npm/bin/node-gyp-bin/node-gyp +2 -0
  13. data/lib/node_modules/npm/bin/node-gyp-bin/node-gyp.cmd +1 -0
  14. data/lib/node_modules/npm/bin/npm +13 -0
  15. data/lib/node_modules/npm/bin/npm-cli.js +87 -0
  16. data/lib/node_modules/npm/bin/npm.cmd +6 -0
  17. data/lib/node_modules/npm/bin/read-package-json.js +22 -0
  18. data/lib/node_modules/npm/cli.js +2 -0
  19. data/lib/node_modules/npm/configure +33 -0
  20. data/lib/node_modules/npm/doc/api/npm-bin.md +13 -0
  21. data/lib/node_modules/npm/doc/api/npm-bugs.md +19 -0
  22. data/lib/node_modules/npm/doc/api/npm-commands.md +22 -0
  23. data/lib/node_modules/npm/doc/api/npm-config.md +45 -0
  24. data/lib/node_modules/npm/doc/api/npm-deprecate.md +34 -0
  25. data/lib/node_modules/npm/doc/api/npm-docs.md +19 -0
  26. data/lib/node_modules/npm/doc/api/npm-edit.md +24 -0
  27. data/lib/node_modules/npm/doc/api/npm-explore.md +18 -0
  28. data/lib/node_modules/npm/doc/api/npm-help-search.md +30 -0
  29. data/lib/node_modules/npm/doc/api/npm-init.md +29 -0
  30. data/lib/node_modules/npm/doc/api/npm-install.md +19 -0
  31. data/lib/node_modules/npm/doc/api/npm-link.md +33 -0
  32. data/lib/node_modules/npm/doc/api/npm-load.md +26 -0
  33. data/lib/node_modules/npm/doc/api/npm-ls.md +56 -0
  34. data/lib/node_modules/npm/doc/api/npm-outdated.md +13 -0
  35. data/lib/node_modules/npm/doc/api/npm-owner.md +31 -0
  36. data/lib/node_modules/npm/doc/api/npm-pack.md +19 -0
  37. data/lib/node_modules/npm/doc/api/npm-prefix.md +15 -0
  38. data/lib/node_modules/npm/doc/api/npm-prune.md +17 -0
  39. data/lib/node_modules/npm/doc/api/npm-publish.md +30 -0
  40. data/lib/node_modules/npm/doc/api/npm-rebuild.md +16 -0
  41. data/lib/node_modules/npm/doc/api/npm-repo.md +19 -0
  42. data/lib/node_modules/npm/doc/api/npm-restart.md +22 -0
  43. data/lib/node_modules/npm/doc/api/npm-root.md +15 -0
  44. data/lib/node_modules/npm/doc/api/npm-run-script.md +27 -0
  45. data/lib/node_modules/npm/doc/api/npm-search.md +35 -0
  46. data/lib/node_modules/npm/doc/api/npm-shrinkwrap.md +20 -0
  47. data/lib/node_modules/npm/doc/api/npm-start.md +13 -0
  48. data/lib/node_modules/npm/doc/api/npm-stop.md +13 -0
  49. data/lib/node_modules/npm/doc/api/npm-submodule.md +28 -0
  50. data/lib/node_modules/npm/doc/api/npm-tag.md +23 -0
  51. data/lib/node_modules/npm/doc/api/npm-test.md +16 -0
  52. data/lib/node_modules/npm/doc/api/npm-uninstall.md +16 -0
  53. data/lib/node_modules/npm/doc/api/npm-unpublish.md +20 -0
  54. data/lib/node_modules/npm/doc/api/npm-update.md +11 -0
  55. data/lib/node_modules/npm/doc/api/npm-version.md +18 -0
  56. data/lib/node_modules/npm/doc/api/npm-view.md +93 -0
  57. data/lib/node_modules/npm/doc/api/npm-whoami.md +15 -0
  58. data/lib/node_modules/npm/doc/api/npm.md +116 -0
  59. data/lib/node_modules/npm/doc/cli/npm-adduser.md +38 -0
  60. data/lib/node_modules/npm/doc/cli/npm-bin.md +19 -0
  61. data/lib/node_modules/npm/doc/cli/npm-bugs.md +42 -0
  62. data/lib/node_modules/npm/doc/cli/npm-build.md +22 -0
  63. data/lib/node_modules/npm/doc/cli/npm-bundle.md +14 -0
  64. data/lib/node_modules/npm/doc/cli/npm-cache.md +72 -0
  65. data/lib/node_modules/npm/doc/cli/npm-completion.md +29 -0
  66. data/lib/node_modules/npm/doc/cli/npm-config.md +71 -0
  67. data/lib/node_modules/npm/doc/cli/npm-dedupe.md +58 -0
  68. data/lib/node_modules/npm/doc/cli/npm-deprecate.md +26 -0
  69. data/lib/node_modules/npm/doc/cli/npm-docs.md +44 -0
  70. data/lib/node_modules/npm/doc/cli/npm-edit.md +37 -0
  71. data/lib/node_modules/npm/doc/cli/npm-explore.md +40 -0
  72. data/lib/node_modules/npm/doc/cli/npm-help-search.md +35 -0
  73. data/lib/node_modules/npm/doc/cli/npm-help.md +40 -0
  74. data/lib/node_modules/npm/doc/cli/npm-init.md +25 -0
  75. data/lib/node_modules/npm/doc/cli/npm-install.md +252 -0
  76. data/lib/node_modules/npm/doc/cli/npm-link.md +63 -0
  77. data/lib/node_modules/npm/doc/cli/npm-ls.md +80 -0
  78. data/lib/node_modules/npm/doc/cli/npm-outdated.md +58 -0
  79. data/lib/node_modules/npm/doc/cli/npm-owner.md +33 -0
  80. data/lib/node_modules/npm/doc/cli/npm-pack.md +27 -0
  81. data/lib/node_modules/npm/doc/cli/npm-prefix.md +19 -0
  82. data/lib/node_modules/npm/doc/cli/npm-prune.md +25 -0
  83. data/lib/node_modules/npm/doc/cli/npm-publish.md +30 -0
  84. data/lib/node_modules/npm/doc/cli/npm-rebuild.md +21 -0
  85. data/lib/node_modules/npm/doc/cli/npm-repo.md +28 -0
  86. data/lib/node_modules/npm/doc/cli/npm-restart.md +22 -0
  87. data/lib/node_modules/npm/doc/cli/npm-rm.md +23 -0
  88. data/lib/node_modules/npm/doc/cli/npm-root.md +19 -0
  89. data/lib/node_modules/npm/doc/cli/npm-run-script.md +21 -0
  90. data/lib/node_modules/npm/doc/cli/npm-search.md +36 -0
  91. data/lib/node_modules/npm/doc/cli/npm-shrinkwrap.md +185 -0
  92. data/lib/node_modules/npm/doc/cli/npm-star.md +22 -0
  93. data/lib/node_modules/npm/doc/cli/npm-stars.md +22 -0
  94. data/lib/node_modules/npm/doc/cli/npm-start.md +18 -0
  95. data/lib/node_modules/npm/doc/cli/npm-stop.md +18 -0
  96. data/lib/node_modules/npm/doc/cli/npm-submodule.md +28 -0
  97. data/lib/node_modules/npm/doc/cli/npm-tag.md +34 -0
  98. data/lib/node_modules/npm/doc/cli/npm-test.md +22 -0
  99. data/lib/node_modules/npm/doc/cli/npm-uninstall.md +21 -0
  100. data/lib/node_modules/npm/doc/cli/npm-unpublish.md +32 -0
  101. data/lib/node_modules/npm/doc/cli/npm-update.md +24 -0
  102. data/lib/node_modules/npm/doc/cli/npm-version.md +45 -0
  103. data/lib/node_modules/npm/doc/cli/npm-view.md +90 -0
  104. data/lib/node_modules/npm/doc/cli/npm-whoami.md +17 -0
  105. data/lib/node_modules/npm/doc/cli/npm.md +153 -0
  106. data/lib/node_modules/npm/doc/files/npm-folders.md +211 -0
  107. data/lib/node_modules/npm/doc/files/npmrc.md +59 -0
  108. data/lib/node_modules/npm/doc/files/package.json.md +576 -0
  109. data/lib/node_modules/npm/doc/misc/npm-coding-style.md +181 -0
  110. data/lib/node_modules/npm/doc/misc/npm-config.md +820 -0
  111. data/lib/node_modules/npm/doc/misc/npm-developers.md +207 -0
  112. data/lib/node_modules/npm/doc/misc/npm-disputes.md +99 -0
  113. data/lib/node_modules/npm/doc/misc/npm-faq.md +364 -0
  114. data/lib/node_modules/npm/doc/misc/npm-index.md +411 -0
  115. data/lib/node_modules/npm/doc/misc/npm-registry.md +69 -0
  116. data/lib/node_modules/npm/doc/misc/npm-scripts.md +245 -0
  117. data/lib/node_modules/npm/doc/misc/removing-npm.md +54 -0
  118. data/lib/node_modules/npm/doc/misc/semver.md +111 -0
  119. data/lib/node_modules/npm/html/doc/README.html +276 -0
  120. data/lib/node_modules/npm/html/doc/api/npm-bin.html +53 -0
  121. data/lib/node_modules/npm/html/doc/api/npm-bugs.html +59 -0
  122. data/lib/node_modules/npm/html/doc/api/npm-commands.html +62 -0
  123. data/lib/node_modules/npm/html/doc/api/npm-config.html +67 -0
  124. data/lib/node_modules/npm/html/doc/api/npm-deprecate.html +66 -0
  125. data/lib/node_modules/npm/html/doc/api/npm-docs.html +59 -0
  126. data/lib/node_modules/npm/html/doc/api/npm-edit.html +64 -0
  127. data/lib/node_modules/npm/html/doc/api/npm-explore.html +58 -0
  128. data/lib/node_modules/npm/html/doc/api/npm-help-search.html +66 -0
  129. data/lib/node_modules/npm/html/doc/api/npm-init.html +69 -0
  130. data/lib/node_modules/npm/html/doc/api/npm-install.html +59 -0
  131. data/lib/node_modules/npm/html/doc/api/npm-link.html +73 -0
  132. data/lib/node_modules/npm/html/doc/api/npm-load.html +66 -0
  133. data/lib/node_modules/npm/html/doc/api/npm-ls.html +93 -0
  134. data/lib/node_modules/npm/html/doc/api/npm-outdated.html +53 -0
  135. data/lib/node_modules/npm/html/doc/api/npm-owner.html +68 -0
  136. data/lib/node_modules/npm/html/doc/api/npm-pack.html +59 -0
  137. data/lib/node_modules/npm/html/doc/api/npm-prefix.html +55 -0
  138. data/lib/node_modules/npm/html/doc/api/npm-prune.html +57 -0
  139. data/lib/node_modules/npm/html/doc/api/npm-publish.html +66 -0
  140. data/lib/node_modules/npm/html/doc/api/npm-rebuild.html +56 -0
  141. data/lib/node_modules/npm/html/doc/api/npm-repo.html +59 -0
  142. data/lib/node_modules/npm/html/doc/api/npm-restart.html +61 -0
  143. data/lib/node_modules/npm/html/doc/api/npm-root.html +55 -0
  144. data/lib/node_modules/npm/html/doc/api/npm-run-script.html +63 -0
  145. data/lib/node_modules/npm/html/doc/api/npm-search.html +66 -0
  146. data/lib/node_modules/npm/html/doc/api/npm-shrinkwrap.html +60 -0
  147. data/lib/node_modules/npm/html/doc/api/npm-start.html +53 -0
  148. data/lib/node_modules/npm/html/doc/api/npm-stop.html +53 -0
  149. data/lib/node_modules/npm/html/doc/api/npm-submodule.html +67 -0
  150. data/lib/node_modules/npm/html/doc/api/npm-tag.html +63 -0
  151. data/lib/node_modules/npm/html/doc/api/npm-test.html +56 -0
  152. data/lib/node_modules/npm/html/doc/api/npm-uninstall.html +56 -0
  153. data/lib/node_modules/npm/html/doc/api/npm-unpublish.html +60 -0
  154. data/lib/node_modules/npm/html/doc/api/npm-update.html +52 -0
  155. data/lib/node_modules/npm/html/doc/api/npm-version.html +58 -0
  156. data/lib/node_modules/npm/html/doc/api/npm-view.html +133 -0
  157. data/lib/node_modules/npm/html/doc/api/npm-whoami.html +55 -0
  158. data/lib/node_modules/npm/html/doc/api/npm.html +126 -0
  159. data/lib/node_modules/npm/html/doc/cli/npm-adduser.html +73 -0
  160. data/lib/node_modules/npm/html/doc/cli/npm-bin.html +54 -0
  161. data/lib/node_modules/npm/html/doc/cli/npm-bugs.html +72 -0
  162. data/lib/node_modules/npm/html/doc/cli/npm-build.html +59 -0
  163. data/lib/node_modules/npm/html/doc/cli/npm-bundle.html +54 -0
  164. data/lib/node_modules/npm/html/doc/cli/npm-cache.html +100 -0
  165. data/lib/node_modules/npm/html/doc/cli/npm-completion.html +67 -0
  166. data/lib/node_modules/npm/html/doc/cli/npm-config.html +107 -0
  167. data/lib/node_modules/npm/html/doc/cli/npm-dedupe.html +96 -0
  168. data/lib/node_modules/npm/html/doc/cli/npm-deprecate.html +65 -0
  169. data/lib/node_modules/npm/html/doc/cli/npm-docs.html +75 -0
  170. data/lib/node_modules/npm/html/doc/cli/npm-edit.html +71 -0
  171. data/lib/node_modules/npm/html/doc/cli/npm-explore.html +74 -0
  172. data/lib/node_modules/npm/html/doc/cli/npm-help-search.html +72 -0
  173. data/lib/node_modules/npm/html/doc/cli/npm-help.html +70 -0
  174. data/lib/node_modules/npm/html/doc/cli/npm-init.html +63 -0
  175. data/lib/node_modules/npm/html/doc/cli/npm-install.html +183 -0
  176. data/lib/node_modules/npm/html/doc/cli/npm-link.html +96 -0
  177. data/lib/node_modules/npm/html/doc/cli/npm-ls.html +108 -0
  178. data/lib/node_modules/npm/html/doc/cli/npm-outdated.html +92 -0
  179. data/lib/node_modules/npm/html/doc/cli/npm-owner.html +68 -0
  180. data/lib/node_modules/npm/html/doc/cli/npm-pack.html +63 -0
  181. data/lib/node_modules/npm/html/doc/cli/npm-prefix.html +54 -0
  182. data/lib/node_modules/npm/html/doc/cli/npm-prune.html +63 -0
  183. data/lib/node_modules/npm/html/doc/cli/npm-publish.html +63 -0
  184. data/lib/node_modules/npm/html/doc/cli/npm-rebuild.html +60 -0
  185. data/lib/node_modules/npm/html/doc/cli/npm-repo.html +66 -0
  186. data/lib/node_modules/npm/html/doc/cli/npm-restart.html +58 -0
  187. data/lib/node_modules/npm/html/doc/cli/npm-rm.html +58 -0
  188. data/lib/node_modules/npm/html/doc/cli/npm-root.html +54 -0
  189. data/lib/node_modules/npm/html/doc/cli/npm-run-script.html +57 -0
  190. data/lib/node_modules/npm/html/doc/cli/npm-search.html +71 -0
  191. data/lib/node_modules/npm/html/doc/cli/npm-shrinkwrap.html +217 -0
  192. data/lib/node_modules/npm/html/doc/cli/npm-star.html +60 -0
  193. data/lib/node_modules/npm/html/doc/cli/npm-stars.html +59 -0
  194. data/lib/node_modules/npm/html/doc/cli/npm-start.html +54 -0
  195. data/lib/node_modules/npm/html/doc/cli/npm-stop.html +54 -0
  196. data/lib/node_modules/npm/html/doc/cli/npm-submodule.html +67 -0
  197. data/lib/node_modules/npm/html/doc/cli/npm-tag.html +68 -0
  198. data/lib/node_modules/npm/html/doc/cli/npm-test.html +58 -0
  199. data/lib/node_modules/npm/html/doc/cli/npm-uninstall.html +56 -0
  200. data/lib/node_modules/npm/html/doc/cli/npm-unpublish.html +68 -0
  201. data/lib/node_modules/npm/html/doc/cli/npm-update.html +60 -0
  202. data/lib/node_modules/npm/html/doc/cli/npm-version.html +83 -0
  203. data/lib/node_modules/npm/html/doc/cli/npm-view.html +125 -0
  204. data/lib/node_modules/npm/html/doc/cli/npm-whoami.html +54 -0
  205. data/lib/node_modules/npm/html/doc/cli/npm.html +165 -0
  206. data/lib/node_modules/npm/html/doc/files/npm-folders.html +239 -0
  207. data/lib/node_modules/npm/html/doc/files/npm-global.html +239 -0
  208. data/lib/node_modules/npm/html/doc/files/npm-json.html +580 -0
  209. data/lib/node_modules/npm/html/doc/files/npmrc.html +93 -0
  210. data/lib/node_modules/npm/html/doc/files/package.json.html +580 -0
  211. data/lib/node_modules/npm/html/doc/index.html +450 -0
  212. data/lib/node_modules/npm/html/doc/misc/npm-coding-style.html +216 -0
  213. data/lib/node_modules/npm/html/doc/misc/npm-config.html +744 -0
  214. data/lib/node_modules/npm/html/doc/misc/npm-developers.html +208 -0
  215. data/lib/node_modules/npm/html/doc/misc/npm-disputes.html +126 -0
  216. data/lib/node_modules/npm/html/doc/misc/npm-faq.html +382 -0
  217. data/lib/node_modules/npm/html/doc/misc/npm-index.html +450 -0
  218. data/lib/node_modules/npm/html/doc/misc/npm-registry.html +105 -0
  219. data/lib/node_modules/npm/html/doc/misc/npm-scripts.html +257 -0
  220. data/lib/node_modules/npm/html/doc/misc/removing-npm.html +92 -0
  221. data/lib/node_modules/npm/html/doc/misc/semver.html +128 -0
  222. data/lib/node_modules/npm/html/docfoot-script.html +31 -0
  223. data/lib/node_modules/npm/html/docfoot.html +2 -0
  224. data/lib/node_modules/npm/html/dochead.html +8 -0
  225. data/lib/node_modules/npm/html/favicon.ico +0 -0
  226. data/lib/node_modules/npm/html/index.html +95 -0
  227. data/lib/node_modules/npm/html/static/style.css +329 -0
  228. data/lib/node_modules/npm/lib/adduser.js +138 -0
  229. data/lib/node_modules/npm/lib/bin.js +18 -0
  230. data/lib/node_modules/npm/lib/bugs.js +61 -0
  231. data/lib/node_modules/npm/lib/build.js +228 -0
  232. data/lib/node_modules/npm/lib/cache.js +1318 -0
  233. data/lib/node_modules/npm/lib/completion.js +253 -0
  234. data/lib/node_modules/npm/lib/config.js +285 -0
  235. data/lib/node_modules/npm/lib/dedupe.js +357 -0
  236. data/lib/node_modules/npm/lib/deprecate.js +47 -0
  237. data/lib/node_modules/npm/lib/docs.js +62 -0
  238. data/lib/node_modules/npm/lib/edit.js +32 -0
  239. data/lib/node_modules/npm/lib/explore.js +36 -0
  240. data/lib/node_modules/npm/lib/faq.js +8 -0
  241. data/lib/node_modules/npm/lib/get.js +12 -0
  242. data/lib/node_modules/npm/lib/help-search.js +218 -0
  243. data/lib/node_modules/npm/lib/help.js +231 -0
  244. data/lib/node_modules/npm/lib/init.js +36 -0
  245. data/lib/node_modules/npm/lib/install.js +979 -0
  246. data/lib/node_modules/npm/lib/link.js +173 -0
  247. data/lib/node_modules/npm/lib/ls.js +357 -0
  248. data/lib/node_modules/npm/lib/npm.js +528 -0
  249. data/lib/node_modules/npm/lib/outdated.js +303 -0
  250. data/lib/node_modules/npm/lib/owner.js +205 -0
  251. data/lib/node_modules/npm/lib/pack.js +65 -0
  252. data/lib/node_modules/npm/lib/prefix.js +11 -0
  253. data/lib/node_modules/npm/lib/prune.js +53 -0
  254. data/lib/node_modules/npm/lib/publish.js +118 -0
  255. data/lib/node_modules/npm/lib/rebuild.js +75 -0
  256. data/lib/node_modules/npm/lib/repo.js +54 -0
  257. data/lib/node_modules/npm/lib/restart.js +1 -0
  258. data/lib/node_modules/npm/lib/root.js +11 -0
  259. data/lib/node_modules/npm/lib/run-script.js +102 -0
  260. data/lib/node_modules/npm/lib/search.js +265 -0
  261. data/lib/node_modules/npm/lib/set.js +13 -0
  262. data/lib/node_modules/npm/lib/shrinkwrap.js +86 -0
  263. data/lib/node_modules/npm/lib/star.js +33 -0
  264. data/lib/node_modules/npm/lib/stars.js +27 -0
  265. data/lib/node_modules/npm/lib/start.js +1 -0
  266. data/lib/node_modules/npm/lib/stop.js +1 -0
  267. data/lib/node_modules/npm/lib/submodule.js +119 -0
  268. data/lib/node_modules/npm/lib/substack.js +20 -0
  269. data/lib/node_modules/npm/lib/tag.js +18 -0
  270. data/lib/node_modules/npm/lib/test.js +14 -0
  271. data/lib/node_modules/npm/lib/unbuild.js +112 -0
  272. data/lib/node_modules/npm/lib/uninstall.js +127 -0
  273. data/lib/node_modules/npm/lib/unpublish.js +83 -0
  274. data/lib/node_modules/npm/lib/update.js +43 -0
  275. data/lib/node_modules/npm/lib/utils/completion.sh +54 -0
  276. data/lib/node_modules/npm/lib/utils/completion/file-completion.js +26 -0
  277. data/lib/node_modules/npm/lib/utils/completion/installed-deep.js +50 -0
  278. data/lib/node_modules/npm/lib/utils/completion/installed-shallow.js +79 -0
  279. data/lib/node_modules/npm/lib/utils/error-handler.js +343 -0
  280. data/lib/node_modules/npm/lib/utils/fetch.js +93 -0
  281. data/lib/node_modules/npm/lib/utils/find-prefix.js +57 -0
  282. data/lib/node_modules/npm/lib/utils/gently-rm.js +61 -0
  283. data/lib/node_modules/npm/lib/utils/is-git-url.js +13 -0
  284. data/lib/node_modules/npm/lib/utils/lifecycle.js +360 -0
  285. data/lib/node_modules/npm/lib/utils/link.js +39 -0
  286. data/lib/node_modules/npm/lib/utils/tar.js +323 -0
  287. data/lib/node_modules/npm/lib/version.js +120 -0
  288. data/lib/node_modules/npm/lib/view.js +246 -0
  289. data/lib/node_modules/npm/lib/visnup.js +42 -0
  290. data/lib/node_modules/npm/lib/whoami.js +13 -0
  291. data/lib/node_modules/npm/lib/xmas.js +56 -0
  292. data/lib/node_modules/npm/make.bat +3 -0
  293. data/lib/node_modules/npm/man/man1/npm-README.1 +328 -0
  294. data/lib/node_modules/npm/man/man1/npm-adduser.1 +63 -0
  295. data/lib/node_modules/npm/man/man1/npm-bin.1 +40 -0
  296. data/lib/node_modules/npm/man/man1/npm-bugs.1 +78 -0
  297. data/lib/node_modules/npm/man/man1/npm-build.1 +43 -0
  298. data/lib/node_modules/npm/man/man1/npm-bundle.1 +23 -0
  299. data/lib/node_modules/npm/man/man1/npm-cache.1 +104 -0
  300. data/lib/node_modules/npm/man/man1/npm-completion.1 +47 -0
  301. data/lib/node_modules/npm/man/man1/npm-config.1 +113 -0
  302. data/lib/node_modules/npm/man/man1/npm-dedupe.1 +96 -0
  303. data/lib/node_modules/npm/man/man1/npm-deprecate.1 +48 -0
  304. data/lib/node_modules/npm/man/man1/npm-docs.1 +78 -0
  305. data/lib/node_modules/npm/man/man1/npm-edit.1 +66 -0
  306. data/lib/node_modules/npm/man/man1/npm-explore.1 +76 -0
  307. data/lib/node_modules/npm/man/man1/npm-help-search.1 +59 -0
  308. data/lib/node_modules/npm/man/man1/npm-help.1 +77 -0
  309. data/lib/node_modules/npm/man/man1/npm-init.1 +43 -0
  310. data/lib/node_modules/npm/man/man1/npm-install.1 +434 -0
  311. data/lib/node_modules/npm/man/man1/npm-link.1 +119 -0
  312. data/lib/node_modules/npm/man/man1/npm-ls.1 +146 -0
  313. data/lib/node_modules/npm/man/man1/npm-outdated.1 +102 -0
  314. data/lib/node_modules/npm/man/man1/npm-owner.1 +58 -0
  315. data/lib/node_modules/npm/man/man1/npm-pack.1 +48 -0
  316. data/lib/node_modules/npm/man/man1/npm-prefix.1 +40 -0
  317. data/lib/node_modules/npm/man/man1/npm-prune.1 +42 -0
  318. data/lib/node_modules/npm/man/man1/npm-publish.1 +53 -0
  319. data/lib/node_modules/npm/man/man1/npm-rebuild.1 +37 -0
  320. data/lib/node_modules/npm/man/man1/npm-repo.1 +47 -0
  321. data/lib/node_modules/npm/man/man1/npm-restart.1 +42 -0
  322. data/lib/node_modules/npm/man/man1/npm-rm.1 +44 -0
  323. data/lib/node_modules/npm/man/man1/npm-root.1 +40 -0
  324. data/lib/node_modules/npm/man/man1/npm-run-script.1 +41 -0
  325. data/lib/node_modules/npm/man/man1/npm-search.1 +62 -0
  326. data/lib/node_modules/npm/man/man1/npm-shrinkwrap.1 +275 -0
  327. data/lib/node_modules/npm/man/man1/npm-star.1 +39 -0
  328. data/lib/node_modules/npm/man/man1/npm-stars.1 +40 -0
  329. data/lib/node_modules/npm/man/man1/npm-start.1 +37 -0
  330. data/lib/node_modules/npm/man/man1/npm-stop.1 +37 -0
  331. data/lib/node_modules/npm/man/man1/npm-submodule.1 +42 -0
  332. data/lib/node_modules/npm/man/man1/npm-tag.1 +74 -0
  333. data/lib/node_modules/npm/man/man1/npm-test.1 +42 -0
  334. data/lib/node_modules/npm/man/man1/npm-uninstall.1 +42 -0
  335. data/lib/node_modules/npm/man/man1/npm-unpublish.1 +53 -0
  336. data/lib/node_modules/npm/man/man1/npm-update.1 +45 -0
  337. data/lib/node_modules/npm/man/man1/npm-version.1 +75 -0
  338. data/lib/node_modules/npm/man/man1/npm-view.1 +186 -0
  339. data/lib/node_modules/npm/man/man1/npm-whoami.1 +34 -0
  340. data/lib/node_modules/npm/man/man1/npm.1 +230 -0
  341. data/lib/node_modules/npm/man/man3/npm-bin.3 +21 -0
  342. data/lib/node_modules/npm/man/man3/npm-bugs.3 +28 -0
  343. data/lib/node_modules/npm/man/man3/npm-commands.3 +35 -0
  344. data/lib/node_modules/npm/man/man3/npm-config.3 +69 -0
  345. data/lib/node_modules/npm/man/man3/npm-deprecate.3 +57 -0
  346. data/lib/node_modules/npm/man/man3/npm-docs.3 +28 -0
  347. data/lib/node_modules/npm/man/man3/npm-edit.3 +35 -0
  348. data/lib/node_modules/npm/man/man3/npm-explore.3 +28 -0
  349. data/lib/node_modules/npm/man/man3/npm-help-search.3 +51 -0
  350. data/lib/node_modules/npm/man/man3/npm-init.3 +39 -0
  351. data/lib/node_modules/npm/man/man3/npm-install.3 +29 -0
  352. data/lib/node_modules/npm/man/man3/npm-link.3 +53 -0
  353. data/lib/node_modules/npm/man/man3/npm-load.3 +44 -0
  354. data/lib/node_modules/npm/man/man3/npm-ls.3 +86 -0
  355. data/lib/node_modules/npm/man/man3/npm-outdated.3 +21 -0
  356. data/lib/node_modules/npm/man/man3/npm-owner.3 +52 -0
  357. data/lib/node_modules/npm/man/man3/npm-pack.3 +28 -0
  358. data/lib/node_modules/npm/man/man3/npm-prefix.3 +24 -0
  359. data/lib/node_modules/npm/man/man3/npm-prune.3 +27 -0
  360. data/lib/node_modules/npm/man/man3/npm-publish.3 +51 -0
  361. data/lib/node_modules/npm/man/man3/npm-rebuild.3 +22 -0
  362. data/lib/node_modules/npm/man/man3/npm-repo.3 +28 -0
  363. data/lib/node_modules/npm/man/man3/npm-restart.3 +37 -0
  364. data/lib/node_modules/npm/man/man3/npm-root.3 +24 -0
  365. data/lib/node_modules/npm/man/man3/npm-run-script.3 +48 -0
  366. data/lib/node_modules/npm/man/man3/npm-search.3 +64 -0
  367. data/lib/node_modules/npm/man/man3/npm-shrinkwrap.3 +30 -0
  368. data/lib/node_modules/npm/man/man3/npm-start.3 +21 -0
  369. data/lib/node_modules/npm/man/man3/npm-stop.3 +21 -0
  370. data/lib/node_modules/npm/man/man3/npm-submodule.3 +42 -0
  371. data/lib/node_modules/npm/man/man3/npm-tag.3 +31 -0
  372. data/lib/node_modules/npm/man/man3/npm-test.3 +25 -0
  373. data/lib/node_modules/npm/man/man3/npm-uninstall.3 +25 -0
  374. data/lib/node_modules/npm/man/man3/npm-unpublish.3 +30 -0
  375. data/lib/node_modules/npm/man/man3/npm-update.3 +18 -0
  376. data/lib/node_modules/npm/man/man3/npm-version.3 +27 -0
  377. data/lib/node_modules/npm/man/man3/npm-view.3 +176 -0
  378. data/lib/node_modules/npm/man/man3/npm-whoami.3 +24 -0
  379. data/lib/node_modules/npm/man/man3/npm.3 +162 -0
  380. data/lib/node_modules/npm/man/man5/npm-folders.5 +264 -0
  381. data/lib/node_modules/npm/man/man5/npm-global.5 +264 -0
  382. data/lib/node_modules/npm/man/man5/npm-json.5 +807 -0
  383. data/lib/node_modules/npm/man/man5/npmrc.5 +89 -0
  384. data/lib/node_modules/npm/man/man5/package.json.5 +807 -0
  385. data/lib/node_modules/npm/man/man7/npm-coding-style.7 +254 -0
  386. data/lib/node_modules/npm/man/man7/npm-config.7 +1445 -0
  387. data/lib/node_modules/npm/man/man7/npm-developers.7 +335 -0
  388. data/lib/node_modules/npm/man/man7/npm-disputes.7 +146 -0
  389. data/lib/node_modules/npm/man/man7/npm-faq.7 +479 -0
  390. data/lib/node_modules/npm/man/man7/npm-index.7 +307 -0
  391. data/lib/node_modules/npm/man/man7/npm-registry.7 +82 -0
  392. data/lib/node_modules/npm/man/man7/npm-scripts.7 +354 -0
  393. data/lib/node_modules/npm/man/man7/removing-npm.7 +107 -0
  394. data/lib/node_modules/npm/man/man7/semver.7 +172 -0
  395. data/lib/node_modules/npm/node_modules/abbrev/LICENSE +23 -0
  396. data/lib/node_modules/npm/node_modules/abbrev/README.md +23 -0
  397. data/lib/node_modules/npm/node_modules/abbrev/lib/abbrev.js +111 -0
  398. data/lib/node_modules/npm/node_modules/abbrev/package.json +25 -0
  399. data/lib/node_modules/npm/node_modules/ansi/README.md +91 -0
  400. data/lib/node_modules/npm/node_modules/ansi/color-spaces.pl +67 -0
  401. data/lib/node_modules/npm/node_modules/ansi/examples/beep/index.js +16 -0
  402. data/lib/node_modules/npm/node_modules/ansi/examples/clear/index.js +15 -0
  403. data/lib/node_modules/npm/node_modules/ansi/examples/cursorPosition.js +32 -0
  404. data/lib/node_modules/npm/node_modules/ansi/examples/progress/index.js +87 -0
  405. data/lib/node_modules/npm/node_modules/ansi/examples/starwars.js +46 -0
  406. data/lib/node_modules/npm/node_modules/ansi/lib/ansi.js +405 -0
  407. data/lib/node_modules/npm/node_modules/ansi/lib/newlines.js +71 -0
  408. data/lib/node_modules/npm/node_modules/ansi/package.json +50 -0
  409. data/lib/node_modules/npm/node_modules/ansicolors/LICENSE +23 -0
  410. data/lib/node_modules/npm/node_modules/ansicolors/README.md +62 -0
  411. data/lib/node_modules/npm/node_modules/ansicolors/ansicolors.js +65 -0
  412. data/lib/node_modules/npm/node_modules/ansicolors/package.json +34 -0
  413. data/lib/node_modules/npm/node_modules/ansistyles/LICENSE +23 -0
  414. data/lib/node_modules/npm/node_modules/ansistyles/README.md +71 -0
  415. data/lib/node_modules/npm/node_modules/ansistyles/ansistyles.js +38 -0
  416. data/lib/node_modules/npm/node_modules/ansistyles/package.json +38 -0
  417. data/lib/node_modules/npm/node_modules/archy/README.markdown +92 -0
  418. data/lib/node_modules/npm/node_modules/archy/index.js +35 -0
  419. data/lib/node_modules/npm/node_modules/archy/package.json +52 -0
  420. data/lib/node_modules/npm/node_modules/block-stream/LICENCE +25 -0
  421. data/lib/node_modules/npm/node_modules/block-stream/README.md +14 -0
  422. data/lib/node_modules/npm/node_modules/block-stream/bench/block-stream-pause.js +70 -0
  423. data/lib/node_modules/npm/node_modules/block-stream/bench/block-stream.js +68 -0
  424. data/lib/node_modules/npm/node_modules/block-stream/bench/dropper-pause.js +70 -0
  425. data/lib/node_modules/npm/node_modules/block-stream/bench/dropper.js +68 -0
  426. data/lib/node_modules/npm/node_modules/block-stream/block-stream.js +209 -0
  427. data/lib/node_modules/npm/node_modules/block-stream/package.json +35 -0
  428. data/lib/node_modules/npm/node_modules/child-process-close/README.md +45 -0
  429. data/lib/node_modules/npm/node_modules/child-process-close/index.js +48 -0
  430. data/lib/node_modules/npm/node_modules/child-process-close/package.json +37 -0
  431. data/lib/node_modules/npm/node_modules/chmodr/LICENSE +27 -0
  432. data/lib/node_modules/npm/node_modules/chmodr/README.md +3 -0
  433. data/lib/node_modules/npm/node_modules/chmodr/chmodr.js +54 -0
  434. data/lib/node_modules/npm/node_modules/chmodr/package.json +28 -0
  435. data/lib/node_modules/npm/node_modules/chownr/LICENCE +25 -0
  436. data/lib/node_modules/npm/node_modules/chownr/README.md +3 -0
  437. data/lib/node_modules/npm/node_modules/chownr/chownr.js +41 -0
  438. data/lib/node_modules/npm/node_modules/chownr/package.json +42 -0
  439. data/lib/node_modules/npm/node_modules/cmd-shim/LICENSE +27 -0
  440. data/lib/node_modules/npm/node_modules/cmd-shim/README.md +42 -0
  441. data/lib/node_modules/npm/node_modules/cmd-shim/index.js +180 -0
  442. data/lib/node_modules/npm/node_modules/cmd-shim/package.json +35 -0
  443. data/lib/node_modules/npm/node_modules/columnify/Readme.md +189 -0
  444. data/lib/node_modules/npm/node_modules/columnify/index.js +210 -0
  445. data/lib/node_modules/npm/node_modules/columnify/package.json +42 -0
  446. data/lib/node_modules/npm/node_modules/columnify/utils.js +76 -0
  447. data/lib/node_modules/npm/node_modules/editor/LICENSE +18 -0
  448. data/lib/node_modules/npm/node_modules/editor/README.markdown +54 -0
  449. data/lib/node_modules/npm/node_modules/editor/example/beep.json +5 -0
  450. data/lib/node_modules/npm/node_modules/editor/example/edit.js +4 -0
  451. data/lib/node_modules/npm/node_modules/editor/index.js +26 -0
  452. data/lib/node_modules/npm/node_modules/editor/package.json +43 -0
  453. data/lib/node_modules/npm/node_modules/fstream-npm/LICENCE +25 -0
  454. data/lib/node_modules/npm/node_modules/fstream-npm/README.md +18 -0
  455. data/lib/node_modules/npm/node_modules/fstream-npm/example/bundle.js +13 -0
  456. data/lib/node_modules/npm/node_modules/fstream-npm/example/dir-tar.js +19 -0
  457. data/lib/node_modules/npm/node_modules/fstream-npm/example/dir.js +25 -0
  458. data/lib/node_modules/npm/node_modules/fstream-npm/example/example.js +12 -0
  459. data/lib/node_modules/npm/node_modules/fstream-npm/example/ig-tar.js +19 -0
  460. data/lib/node_modules/npm/node_modules/fstream-npm/example/tar.js +25 -0
  461. data/lib/node_modules/npm/node_modules/fstream-npm/fstream-npm.js +323 -0
  462. data/lib/node_modules/npm/node_modules/fstream-npm/node_modules/fstream-ignore/LICENSE +27 -0
  463. data/lib/node_modules/npm/node_modules/fstream-npm/node_modules/fstream-ignore/README.md +22 -0
  464. data/lib/node_modules/npm/node_modules/fstream-npm/node_modules/fstream-ignore/example/basic.js +13 -0
  465. data/lib/node_modules/npm/node_modules/fstream-npm/node_modules/fstream-ignore/ignore.js +275 -0
  466. data/lib/node_modules/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json +40 -0
  467. data/lib/node_modules/npm/node_modules/fstream-npm/package.json +27 -0
  468. data/lib/node_modules/npm/node_modules/fstream/LICENSE +27 -0
  469. data/lib/node_modules/npm/node_modules/fstream/README.md +76 -0
  470. data/lib/node_modules/npm/node_modules/fstream/examples/filter-pipe.js +131 -0
  471. data/lib/node_modules/npm/node_modules/fstream/examples/pipe.js +115 -0
  472. data/lib/node_modules/npm/node_modules/fstream/examples/reader.js +54 -0
  473. data/lib/node_modules/npm/node_modules/fstream/examples/symlink-write.js +24 -0
  474. data/lib/node_modules/npm/node_modules/fstream/fstream.js +31 -0
  475. data/lib/node_modules/npm/node_modules/fstream/lib/abstract.js +85 -0
  476. data/lib/node_modules/npm/node_modules/fstream/lib/collect.js +67 -0
  477. data/lib/node_modules/npm/node_modules/fstream/lib/dir-reader.js +251 -0
  478. data/lib/node_modules/npm/node_modules/fstream/lib/dir-writer.js +171 -0
  479. data/lib/node_modules/npm/node_modules/fstream/lib/file-reader.js +147 -0
  480. data/lib/node_modules/npm/node_modules/fstream/lib/file-writer.js +100 -0
  481. data/lib/node_modules/npm/node_modules/fstream/lib/get-type.js +32 -0
  482. data/lib/node_modules/npm/node_modules/fstream/lib/link-reader.js +54 -0
  483. data/lib/node_modules/npm/node_modules/fstream/lib/link-writer.js +95 -0
  484. data/lib/node_modules/npm/node_modules/fstream/lib/proxy-reader.js +93 -0
  485. data/lib/node_modules/npm/node_modules/fstream/lib/proxy-writer.js +109 -0
  486. data/lib/node_modules/npm/node_modules/fstream/lib/reader.js +260 -0
  487. data/lib/node_modules/npm/node_modules/fstream/lib/socket-reader.js +38 -0
  488. data/lib/node_modules/npm/node_modules/fstream/lib/writer.js +389 -0
  489. data/lib/node_modules/npm/node_modules/fstream/package.json +43 -0
  490. data/lib/node_modules/npm/node_modules/github-url-from-git/History.md +10 -0
  491. data/lib/node_modules/npm/node_modules/github-url-from-git/Makefile +5 -0
  492. data/lib/node_modules/npm/node_modules/github-url-from-git/Readme.md +41 -0
  493. data/lib/node_modules/npm/node_modules/github-url-from-git/index.js +12 -0
  494. data/lib/node_modules/npm/node_modules/github-url-from-git/package.json +31 -0
  495. data/lib/node_modules/npm/node_modules/github-url-from-git/test.js +40 -0
  496. data/lib/node_modules/npm/node_modules/github-url-from-username-repo/LICENSE +27 -0
  497. data/lib/node_modules/npm/node_modules/github-url-from-username-repo/README.md +14 -0
  498. data/lib/node_modules/npm/node_modules/github-url-from-username-repo/index.js +9 -0
  499. data/lib/node_modules/npm/node_modules/github-url-from-username-repo/package.json +33 -0
  500. data/lib/node_modules/npm/node_modules/glob/LICENSE +27 -0
  501. data/lib/node_modules/npm/node_modules/glob/README.md +250 -0
  502. data/lib/node_modules/npm/node_modules/glob/examples/g.js +9 -0
  503. data/lib/node_modules/npm/node_modules/glob/examples/usr-local.js +9 -0
  504. data/lib/node_modules/npm/node_modules/glob/glob.js +680 -0
  505. data/lib/node_modules/npm/node_modules/glob/package.json +39 -0
  506. data/lib/node_modules/npm/node_modules/graceful-fs/LICENSE +27 -0
  507. data/lib/node_modules/npm/node_modules/graceful-fs/README.md +26 -0
  508. data/lib/node_modules/npm/node_modules/graceful-fs/graceful-fs.js +161 -0
  509. data/lib/node_modules/npm/node_modules/graceful-fs/package.json +48 -0
  510. data/lib/node_modules/npm/node_modules/graceful-fs/polyfills.js +228 -0
  511. data/lib/node_modules/npm/node_modules/inherits/LICENSE +16 -0
  512. data/lib/node_modules/npm/node_modules/inherits/README.md +42 -0
  513. data/lib/node_modules/npm/node_modules/inherits/inherits.js +1 -0
  514. data/lib/node_modules/npm/node_modules/inherits/inherits_browser.js +23 -0
  515. data/lib/node_modules/npm/node_modules/inherits/package.json +32 -0
  516. data/lib/node_modules/npm/node_modules/inherits/test.js +25 -0
  517. data/lib/node_modules/npm/node_modules/ini/LICENSE +23 -0
  518. data/lib/node_modules/npm/node_modules/ini/README.md +79 -0
  519. data/lib/node_modules/npm/node_modules/ini/ini.js +166 -0
  520. data/lib/node_modules/npm/node_modules/ini/package.json +29 -0
  521. data/lib/node_modules/npm/node_modules/init-package-json/README.md +43 -0
  522. data/lib/node_modules/npm/node_modules/init-package-json/default-input.js +181 -0
  523. data/lib/node_modules/npm/node_modules/init-package-json/example/example-basic.js +8 -0
  524. data/lib/node_modules/npm/node_modules/init-package-json/example/example-default.js +7 -0
  525. data/lib/node_modules/npm/node_modules/init-package-json/example/example-npm.js +13 -0
  526. data/lib/node_modules/npm/node_modules/init-package-json/example/init/basic-init.js +1 -0
  527. data/lib/node_modules/npm/node_modules/init-package-json/init-package-json.js +129 -0
  528. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/LICENSE +15 -0
  529. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/README.md +133 -0
  530. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/index.js +11 -0
  531. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/npm-init/README.md +8 -0
  532. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/npm-init/init-input.js +191 -0
  533. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/npm-init/init.js +37 -0
  534. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/npm-init/package.json +10 -0
  535. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/example/substack-input.js +61 -0
  536. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/package.json +32 -0
  537. data/lib/node_modules/npm/node_modules/init-package-json/node_modules/promzard/promzard.js +216 -0
  538. data/lib/node_modules/npm/node_modules/init-package-json/package.json +48 -0
  539. data/lib/node_modules/npm/node_modules/lockfile/LICENSE +27 -0
  540. data/lib/node_modules/npm/node_modules/lockfile/README.md +81 -0
  541. data/lib/node_modules/npm/node_modules/lockfile/lockfile.js +272 -0
  542. data/lib/node_modules/npm/node_modules/lockfile/package.json +45 -0
  543. data/lib/node_modules/npm/node_modules/lru-cache/CONTRIBUTORS +14 -0
  544. data/lib/node_modules/npm/node_modules/lru-cache/LICENSE +23 -0
  545. data/lib/node_modules/npm/node_modules/lru-cache/README.md +97 -0
  546. data/lib/node_modules/npm/node_modules/lru-cache/lib/lru-cache.js +252 -0
  547. data/lib/node_modules/npm/node_modules/lru-cache/package.json +33 -0
  548. data/lib/node_modules/npm/node_modules/minimatch/LICENSE +23 -0
  549. data/lib/node_modules/npm/node_modules/minimatch/README.md +218 -0
  550. data/lib/node_modules/npm/node_modules/minimatch/minimatch.js +1055 -0
  551. data/lib/node_modules/npm/node_modules/minimatch/node_modules/sigmund/LICENSE +27 -0
  552. data/lib/node_modules/npm/node_modules/minimatch/node_modules/sigmund/README.md +53 -0
  553. data/lib/node_modules/npm/node_modules/minimatch/node_modules/sigmund/bench.js +283 -0
  554. data/lib/node_modules/npm/node_modules/minimatch/node_modules/sigmund/package.json +42 -0
  555. data/lib/node_modules/npm/node_modules/minimatch/node_modules/sigmund/sigmund.js +39 -0
  556. data/lib/node_modules/npm/node_modules/minimatch/package.json +40 -0
  557. data/lib/node_modules/npm/node_modules/mkdirp/LICENSE +21 -0
  558. data/lib/node_modules/npm/node_modules/mkdirp/README.markdown +63 -0
  559. data/lib/node_modules/npm/node_modules/mkdirp/examples/pow.js +6 -0
  560. data/lib/node_modules/npm/node_modules/mkdirp/index.js +82 -0
  561. data/lib/node_modules/npm/node_modules/mkdirp/package.json +33 -0
  562. data/lib/node_modules/npm/node_modules/node-gyp/LICENSE +24 -0
  563. data/lib/node_modules/npm/node_modules/node-gyp/README.md +163 -0
  564. data/lib/node_modules/npm/node_modules/node-gyp/addon.gypi +59 -0
  565. data/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js +133 -0
  566. data/lib/node_modules/npm/node_modules/node-gyp/gyp/AUTHORS +10 -0
  567. data/lib/node_modules/npm/node_modules/node-gyp/gyp/DEPS +24 -0
  568. data/lib/node_modules/npm/node_modules/node-gyp/gyp/LICENSE +27 -0
  569. data/lib/node_modules/npm/node_modules/node-gyp/gyp/OWNERS +1 -0
  570. data/lib/node_modules/npm/node_modules/node-gyp/gyp/PRESUBMIT.py +115 -0
  571. data/lib/node_modules/npm/node_modules/node-gyp/gyp/buildbot/buildbot_run.py +148 -0
  572. data/lib/node_modules/npm/node_modules/node-gyp/gyp/codereview.settings +10 -0
  573. data/lib/node_modules/npm/node_modules/node-gyp/gyp/data/win/large-pdb-shim.cc +12 -0
  574. data/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp +7 -0
  575. data/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp.bat +5 -0
  576. data/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_dummy.c +7 -0
  577. data/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py +18 -0
  578. data/lib/node_modules/npm/node_modules/node-gyp/gyp/gyptest.py +274 -0
  579. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSNew.py +340 -0
  580. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSProject.py +208 -0
  581. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSSettings.py +1051 -0
  582. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSSettings_test.py +1482 -0
  583. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSToolFile.py +58 -0
  584. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSUserFile.py +147 -0
  585. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSUtil.py +267 -0
  586. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/MSVSVersion.py +407 -0
  587. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/__init__.py +537 -0
  588. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/common.py +513 -0
  589. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/common_test.py +72 -0
  590. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/easy_xml.py +157 -0
  591. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/easy_xml_test.py +103 -0
  592. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/flock_tool.py +49 -0
  593. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/__init__.py +0 -0
  594. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/android.py +1069 -0
  595. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/dump_dependency_json.py +81 -0
  596. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/eclipse.py +308 -0
  597. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/gypd.py +87 -0
  598. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/gypsh.py +56 -0
  599. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/make.py +2172 -0
  600. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/msvs.py +3270 -0
  601. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/msvs_test.py +37 -0
  602. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/ninja.py +2150 -0
  603. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/ninja_test.py +44 -0
  604. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/xcode.py +1224 -0
  605. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/generator/xcode_test.py +23 -0
  606. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/input.py +2809 -0
  607. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/input_test.py +90 -0
  608. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/mac_tool.py +264 -0
  609. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/msvs_emulation.py +870 -0
  610. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/ninja_syntax.py +160 -0
  611. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/win_tool.py +176 -0
  612. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/xcode_emulation.py +1324 -0
  613. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/xcodeproj_file.py +2888 -0
  614. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib/gyp/xml_fix.py +69 -0
  615. data/lib/node_modules/npm/node_modules/node-gyp/gyp/pylintrc +307 -0
  616. data/lib/node_modules/npm/node_modules/node-gyp/gyp/samples/samples +81 -0
  617. data/lib/node_modules/npm/node_modules/node-gyp/gyp/samples/samples.bat +5 -0
  618. data/lib/node_modules/npm/node_modules/node-gyp/gyp/setup.py +19 -0
  619. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/README +15 -0
  620. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/Xcode/README +5 -0
  621. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/Xcode/Specifications/gyp.pbfilespec +27 -0
  622. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/Xcode/Specifications/gyp.xclangspec +226 -0
  623. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/README +12 -0
  624. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/gyp-tests.el +63 -0
  625. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/gyp.el +252 -0
  626. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/run-unit-tests.sh +7 -0
  627. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/testdata/media.gyp +1105 -0
  628. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/emacs/testdata/media.gyp.fontified +1107 -0
  629. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/graphviz.py +100 -0
  630. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/pretty_gyp.py +155 -0
  631. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/pretty_sln.py +168 -0
  632. data/lib/node_modules/npm/node_modules/node-gyp/gyp/tools/pretty_vcproj.py +329 -0
  633. data/lib/node_modules/npm/node_modules/node-gyp/lib/build.js +275 -0
  634. data/lib/node_modules/npm/node_modules/node-gyp/lib/clean.js +22 -0
  635. data/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js +344 -0
  636. data/lib/node_modules/npm/node_modules/node-gyp/lib/install.js +362 -0
  637. data/lib/node_modules/npm/node_modules/node-gyp/lib/list.js +33 -0
  638. data/lib/node_modules/npm/node_modules/node-gyp/lib/node-gyp.js +225 -0
  639. data/lib/node_modules/npm/node_modules/node-gyp/lib/rebuild.js +16 -0
  640. data/lib/node_modules/npm/node_modules/node-gyp/lib/remove.js +56 -0
  641. data/lib/node_modules/npm/node_modules/node-gyp/package.json +55 -0
  642. data/lib/node_modules/npm/node_modules/nopt/LICENSE +23 -0
  643. data/lib/node_modules/npm/node_modules/nopt/README.md +210 -0
  644. data/lib/node_modules/npm/node_modules/nopt/bin/nopt.js +51 -0
  645. data/lib/node_modules/npm/node_modules/nopt/examples/my-program.js +30 -0
  646. data/lib/node_modules/npm/node_modules/nopt/lib/nopt.js +407 -0
  647. data/lib/node_modules/npm/node_modules/nopt/package.json +39 -0
  648. data/lib/node_modules/npm/node_modules/npm-install-checks/LICENSE +234 -0
  649. data/lib/node_modules/npm/node_modules/npm-install-checks/README.md +25 -0
  650. data/lib/node_modules/npm/node_modules/npm-install-checks/index.js +146 -0
  651. data/lib/node_modules/npm/node_modules/npm-install-checks/package.json +43 -0
  652. data/lib/node_modules/npm/node_modules/npm-registry-client/LICENSE +27 -0
  653. data/lib/node_modules/npm/node_modules/npm-registry-client/README.md +176 -0
  654. data/lib/node_modules/npm/node_modules/npm-registry-client/index.js +55 -0
  655. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/adduser.js +138 -0
  656. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/bugs.js +9 -0
  657. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/deprecate.js +28 -0
  658. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/get.js +184 -0
  659. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/publish.js +156 -0
  660. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/request.js +270 -0
  661. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/star.js +29 -0
  662. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/stars.js +9 -0
  663. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/tag.js +6 -0
  664. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/unpublish.js +104 -0
  665. data/lib/node_modules/npm/node_modules/npm-registry-client/lib/upload.js +22 -0
  666. data/lib/node_modules/npm/node_modules/npm-registry-client/package.json +43 -0
  667. data/lib/node_modules/npm/node_modules/npm-user-validate/LICENSE +27 -0
  668. data/lib/node_modules/npm/node_modules/npm-user-validate/README.md +6 -0
  669. data/lib/node_modules/npm/node_modules/npm-user-validate/npm-user-validate.js +49 -0
  670. data/lib/node_modules/npm/node_modules/npm-user-validate/package.json +37 -0
  671. data/lib/node_modules/npm/node_modules/npmconf/LICENSE +27 -0
  672. data/lib/node_modules/npm/node_modules/npmconf/README.md +33 -0
  673. data/lib/node_modules/npm/node_modules/npmconf/config-defs.js +353 -0
  674. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/LICENCE +22 -0
  675. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/index.js +282 -0
  676. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/LICENSE +23 -0
  677. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/README.md +3 -0
  678. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/package.json +33 -0
  679. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/proto-list.js +81 -0
  680. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/package.json +32 -0
  681. data/lib/node_modules/npm/node_modules/npmconf/node_modules/config-chain/readme.markdown +228 -0
  682. data/lib/node_modules/npm/node_modules/npmconf/npmconf.js +338 -0
  683. data/lib/node_modules/npm/node_modules/npmconf/package.json +50 -0
  684. data/lib/node_modules/npm/node_modules/npmlog/LICENSE +27 -0
  685. data/lib/node_modules/npm/node_modules/npmlog/README.md +153 -0
  686. data/lib/node_modules/npm/node_modules/npmlog/example.js +39 -0
  687. data/lib/node_modules/npm/node_modules/npmlog/log.js +154 -0
  688. data/lib/node_modules/npm/node_modules/npmlog/package.json +32 -0
  689. data/lib/node_modules/npm/node_modules/once/LICENSE +27 -0
  690. data/lib/node_modules/npm/node_modules/once/README.md +51 -0
  691. data/lib/node_modules/npm/node_modules/once/once.js +20 -0
  692. data/lib/node_modules/npm/node_modules/once/package.json +39 -0
  693. data/lib/node_modules/npm/node_modules/opener/LICENSE.txt +14 -0
  694. data/lib/node_modules/npm/node_modules/opener/README.md +44 -0
  695. data/lib/node_modules/npm/node_modules/opener/opener.js +55 -0
  696. data/lib/node_modules/npm/node_modules/opener/package.json +34 -0
  697. data/lib/node_modules/npm/node_modules/osenv/LICENSE +25 -0
  698. data/lib/node_modules/npm/node_modules/osenv/README.md +63 -0
  699. data/lib/node_modules/npm/node_modules/osenv/osenv.js +80 -0
  700. data/lib/node_modules/npm/node_modules/osenv/package.json +38 -0
  701. data/lib/node_modules/npm/node_modules/path-is-inside/LICENSE.txt +14 -0
  702. data/lib/node_modules/npm/node_modules/path-is-inside/README.md +35 -0
  703. data/lib/node_modules/npm/node_modules/path-is-inside/lib/path-is-inside.js +24 -0
  704. data/lib/node_modules/npm/node_modules/path-is-inside/package.json +39 -0
  705. data/lib/node_modules/npm/node_modules/read-installed/LICENSE +16 -0
  706. data/lib/node_modules/npm/node_modules/read-installed/README.md +25 -0
  707. data/lib/node_modules/npm/node_modules/read-installed/package.json +39 -0
  708. data/lib/node_modules/npm/node_modules/read-installed/read-installed.js +338 -0
  709. data/lib/node_modules/npm/node_modules/read-package-json/LICENSE +15 -0
  710. data/lib/node_modules/npm/node_modules/read-package-json/README.md +166 -0
  711. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/AUTHORS +4 -0
  712. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/LICENSE +30 -0
  713. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/README.md +101 -0
  714. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/core_module_names.json +29 -0
  715. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/extract_description.js +14 -0
  716. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/fixer.js +392 -0
  717. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/normalize.js +36 -0
  718. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/safe_format.js +9 -0
  719. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/typos.json +25 -0
  720. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/lib/warning_messages.json +28 -0
  721. data/lib/node_modules/npm/node_modules/read-package-json/node_modules/normalize-package-data/package.json +53 -0
  722. data/lib/node_modules/npm/node_modules/read-package-json/package.json +39 -0
  723. data/lib/node_modules/npm/node_modules/read-package-json/read-json.js +368 -0
  724. data/lib/node_modules/npm/node_modules/read/LICENCE +25 -0
  725. data/lib/node_modules/npm/node_modules/read/README.md +53 -0
  726. data/lib/node_modules/npm/node_modules/read/example/example.js +13 -0
  727. data/lib/node_modules/npm/node_modules/read/lib/read.js +113 -0
  728. data/lib/node_modules/npm/node_modules/read/node_modules/mute-stream/LICENSE +27 -0
  729. data/lib/node_modules/npm/node_modules/read/node_modules/mute-stream/README.md +68 -0
  730. data/lib/node_modules/npm/node_modules/read/node_modules/mute-stream/mute.js +140 -0
  731. data/lib/node_modules/npm/node_modules/read/node_modules/mute-stream/package.json +37 -0
  732. data/lib/node_modules/npm/node_modules/read/package.json +35 -0
  733. data/lib/node_modules/npm/node_modules/read/rs.js +4 -0
  734. data/lib/node_modules/npm/node_modules/request/LICENSE +55 -0
  735. data/lib/node_modules/npm/node_modules/request/README.md +364 -0
  736. data/lib/node_modules/npm/node_modules/request/index.js +157 -0
  737. data/lib/node_modules/npm/node_modules/request/lib/copy.js +8 -0
  738. data/lib/node_modules/npm/node_modules/request/lib/debug.js +7 -0
  739. data/lib/node_modules/npm/node_modules/request/lib/getSafe.js +34 -0
  740. data/lib/node_modules/npm/node_modules/request/lib/optional.js +5 -0
  741. data/lib/node_modules/npm/node_modules/request/node_modules/aws-sign2/LICENSE +55 -0
  742. data/lib/node_modules/npm/node_modules/request/node_modules/aws-sign2/README.md +4 -0
  743. data/lib/node_modules/npm/node_modules/request/node_modules/aws-sign2/index.js +202 -0
  744. data/lib/node_modules/npm/node_modules/request/node_modules/aws-sign2/package.json +28 -0
  745. data/lib/node_modules/npm/node_modules/request/node_modules/forever-agent/LICENSE +55 -0
  746. data/lib/node_modules/npm/node_modules/request/node_modules/forever-agent/README.md +4 -0
  747. data/lib/node_modules/npm/node_modules/request/node_modules/forever-agent/index.js +119 -0
  748. data/lib/node_modules/npm/node_modules/request/node_modules/forever-agent/package.json +28 -0
  749. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/License +19 -0
  750. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/Readme.md +163 -0
  751. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/lib/form_data.js +325 -0
  752. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/async/LICENSE +19 -0
  753. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/async/README.md +1414 -0
  754. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/async/component.json +11 -0
  755. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/async/lib/async.js +955 -0
  756. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json +43 -0
  757. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/License +19 -0
  758. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/Makefile +7 -0
  759. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/Readme.md +132 -0
  760. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/lib/combined_stream.js +185 -0
  761. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/License +19 -0
  762. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/Makefile +7 -0
  763. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/Readme.md +154 -0
  764. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/lib/delayed_stream.js +99 -0
  765. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/package.json +31 -0
  766. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/package.json +32 -0
  767. data/lib/node_modules/npm/node_modules/request/node_modules/form-data/package.json +46 -0
  768. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/LICENSE +24 -0
  769. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/Makefile +10 -0
  770. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/README.md +627 -0
  771. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/example/usage.js +78 -0
  772. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/images/hawk.png +0 -0
  773. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/images/logo.png +0 -0
  774. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/index.js +1 -0
  775. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/browser.js +485 -0
  776. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/client.js +367 -0
  777. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/crypto.js +111 -0
  778. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/index.js +15 -0
  779. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/server.js +524 -0
  780. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/lib/utils.js +183 -0
  781. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/LICENSE +24 -0
  782. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/Makefile +11 -0
  783. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/README.md +6 -0
  784. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/images/boom.png +0 -0
  785. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/index.js +1 -0
  786. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/lib/index.js +207 -0
  787. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json +47 -0
  788. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/LICENSE +24 -0
  789. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/Makefile +11 -0
  790. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/README.md +6 -0
  791. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/index.js +1 -0
  792. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/lib/index.js +68 -0
  793. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json +48 -0
  794. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/LICENSE +33 -0
  795. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/Makefile +10 -0
  796. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/README.md +436 -0
  797. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/images/hoek.png +0 -0
  798. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/index.js +1 -0
  799. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/lib/escape.js +132 -0
  800. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/lib/index.js +585 -0
  801. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/hoek/package.json +49 -0
  802. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/LICENSE +24 -0
  803. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/Makefile +11 -0
  804. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/README.md +68 -0
  805. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/examples/offset.js +16 -0
  806. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/examples/time.js +25 -0
  807. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/index.js +1 -0
  808. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/lib/index.js +409 -0
  809. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json +48 -0
  810. data/lib/node_modules/npm/node_modules/request/node_modules/hawk/package.json +53 -0
  811. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/LICENSE +18 -0
  812. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/README.md +75 -0
  813. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/http_signing.md +296 -0
  814. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/lib/index.js +25 -0
  815. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/lib/parser.js +304 -0
  816. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/lib/signer.js +179 -0
  817. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/lib/util.js +249 -0
  818. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/lib/verify.js +42 -0
  819. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/LICENSE +19 -0
  820. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/README.md +50 -0
  821. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/ber/errors.js +13 -0
  822. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/ber/index.js +27 -0
  823. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/ber/reader.js +267 -0
  824. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/ber/types.js +36 -0
  825. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/ber/writer.js +317 -0
  826. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/lib/index.js +20 -0
  827. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json +43 -0
  828. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/tst/ber/reader.test.js +172 -0
  829. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/tst/ber/writer.test.js +296 -0
  830. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/README.md +126 -0
  831. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/assert.js +196 -0
  832. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json +20 -0
  833. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/CHANGELOG +71 -0
  834. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/LICENSE +24 -0
  835. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/README +82 -0
  836. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/README.old +298 -0
  837. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/ctf.js +245 -0
  838. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/ctio.js +1485 -0
  839. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/ctype.js +944 -0
  840. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/man/man3ctype/ctio.3ctype +241 -0
  841. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json +18 -0
  842. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tools/jsl.conf +129 -0
  843. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tools/jsstyle +839 -0
  844. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/float.json +13 -0
  845. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/int.json +13 -0
  846. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/psinfo.json +104 -0
  847. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/struct.json +19 -0
  848. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.fail.js +39 -0
  849. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.float.js +14 -0
  850. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.int.js +14 -0
  851. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.psinfo.js +17 -0
  852. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.struct.js +18 -0
  853. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/tst.typedef.js +15 -0
  854. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctf/typedef.json +14 -0
  855. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/float/tst.rfloat.js +767 -0
  856. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/float/tst.wfloat.js +753 -0
  857. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/int/tst.64.js +638 -0
  858. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/int/tst.rint.js +101 -0
  859. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/int/tst.wbounds.js +53 -0
  860. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/int/tst.wint.js +92 -0
  861. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/uint/tst.64.js +451 -0
  862. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/uint/tst.roundtrip.js +81 -0
  863. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/uint/tst.ruint.js +95 -0
  864. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctio/uint/tst.wuint.js +156 -0
  865. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.basicr.js +50 -0
  866. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.basicw.js +44 -0
  867. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.char.js +42 -0
  868. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.endian.js +45 -0
  869. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.oldwrite.js +28 -0
  870. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.readSize.js +128 -0
  871. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.structw.js +28 -0
  872. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/tst/ctype/tst.writeStruct.js +31 -0
  873. data/lib/node_modules/npm/node_modules/request/node_modules/http-signature/package.json +36 -0
  874. data/lib/node_modules/npm/node_modules/request/node_modules/json-stringify-safe/LICENSE +27 -0
  875. data/lib/node_modules/npm/node_modules/request/node_modules/json-stringify-safe/README.md +49 -0
  876. data/lib/node_modules/npm/node_modules/request/node_modules/json-stringify-safe/package.json +33 -0
  877. data/lib/node_modules/npm/node_modules/request/node_modules/json-stringify-safe/stringify.js +39 -0
  878. data/lib/node_modules/npm/node_modules/request/node_modules/json-stringify-safe/test.js +128 -0
  879. data/lib/node_modules/npm/node_modules/request/node_modules/mime/LICENSE +19 -0
  880. data/lib/node_modules/npm/node_modules/request/node_modules/mime/README.md +66 -0
  881. data/lib/node_modules/npm/node_modules/request/node_modules/mime/mime.js +114 -0
  882. data/lib/node_modules/npm/node_modules/request/node_modules/mime/package.json +36 -0
  883. data/lib/node_modules/npm/node_modules/request/node_modules/mime/test.js +84 -0
  884. data/lib/node_modules/npm/node_modules/request/node_modules/mime/types/mime.types +1588 -0
  885. data/lib/node_modules/npm/node_modules/request/node_modules/mime/types/node.types +77 -0
  886. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/LICENSE.md +2 -0
  887. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/README.md +207 -0
  888. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/benchmark/README.md +53 -0
  889. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/benchmark/bench.gnu +174 -0
  890. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/benchmark/bench.sh +34 -0
  891. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/benchmark/benchmark-native.c +34 -0
  892. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/benchmark/benchmark.js +84 -0
  893. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/component.json +18 -0
  894. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/package.json +35 -0
  895. data/lib/node_modules/npm/node_modules/request/node_modules/node-uuid/uuid.js +245 -0
  896. data/lib/node_modules/npm/node_modules/request/node_modules/oauth-sign/LICENSE +55 -0
  897. data/lib/node_modules/npm/node_modules/request/node_modules/oauth-sign/README.md +4 -0
  898. data/lib/node_modules/npm/node_modules/request/node_modules/oauth-sign/index.js +43 -0
  899. data/lib/node_modules/npm/node_modules/request/node_modules/oauth-sign/package.json +31 -0
  900. data/lib/node_modules/npm/node_modules/request/node_modules/oauth-sign/test.js +49 -0
  901. data/lib/node_modules/npm/node_modules/request/node_modules/qs/Readme.md +58 -0
  902. data/lib/node_modules/npm/node_modules/request/node_modules/qs/index.js +366 -0
  903. data/lib/node_modules/npm/node_modules/request/node_modules/qs/package.json +38 -0
  904. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/LICENSE +78 -0
  905. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/README.md +380 -0
  906. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/generate-pubsuffix.js +230 -0
  907. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/lib/cookie.js +947 -0
  908. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/lib/memstore.js +102 -0
  909. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/lib/pubsuffix.js +69 -0
  910. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-GPL.txt +278 -0
  911. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-MIT.txt +20 -0
  912. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/package.json +73 -0
  913. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.js +508 -0
  914. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.min.js +2 -0
  915. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/LICENSE.txt +20 -0
  916. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/README.md +35 -0
  917. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/doc/README.md +69 -0
  918. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/doc/parse.php +35 -0
  919. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/docdown.php +38 -0
  920. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/src/DocDown/Alias.php +226 -0
  921. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/src/DocDown/Entry.php +442 -0
  922. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/vendor/docdown/src/DocDown/Generator.php +563 -0
  923. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/package.json +46 -0
  924. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/public-suffix.txt +5229 -0
  925. data/lib/node_modules/npm/node_modules/request/node_modules/tough-cookie/test.js +1340 -0
  926. data/lib/node_modules/npm/node_modules/request/node_modules/tunnel-agent/LICENSE +55 -0
  927. data/lib/node_modules/npm/node_modules/request/node_modules/tunnel-agent/README.md +4 -0
  928. data/lib/node_modules/npm/node_modules/request/node_modules/tunnel-agent/index.js +227 -0
  929. data/lib/node_modules/npm/node_modules/request/node_modules/tunnel-agent/package.json +28 -0
  930. data/lib/node_modules/npm/node_modules/request/package.json +57 -0
  931. data/lib/node_modules/npm/node_modules/request/request.js +1260 -0
  932. data/lib/node_modules/npm/node_modules/retry/License +21 -0
  933. data/lib/node_modules/npm/node_modules/retry/Makefile +7 -0
  934. data/lib/node_modules/npm/node_modules/retry/Readme.md +167 -0
  935. data/lib/node_modules/npm/node_modules/retry/equation.gif +0 -0
  936. data/lib/node_modules/npm/node_modules/retry/example/dns.js +31 -0
  937. data/lib/node_modules/npm/node_modules/retry/index.js +1 -0
  938. data/lib/node_modules/npm/node_modules/retry/lib/retry.js +50 -0
  939. data/lib/node_modules/npm/node_modules/retry/lib/retry_operation.js +109 -0
  940. data/lib/node_modules/npm/node_modules/retry/package.json +29 -0
  941. data/lib/node_modules/npm/node_modules/rimraf/AUTHORS +6 -0
  942. data/lib/node_modules/npm/node_modules/rimraf/LICENSE +23 -0
  943. data/lib/node_modules/npm/node_modules/rimraf/README.md +30 -0
  944. data/lib/node_modules/npm/node_modules/rimraf/bin.js +33 -0
  945. data/lib/node_modules/npm/node_modules/rimraf/package.json +56 -0
  946. data/lib/node_modules/npm/node_modules/rimraf/rimraf.js +178 -0
  947. data/lib/node_modules/npm/node_modules/semver/LICENSE +27 -0
  948. data/lib/node_modules/npm/node_modules/semver/Makefile +24 -0
  949. data/lib/node_modules/npm/node_modules/semver/README.md +142 -0
  950. data/lib/node_modules/npm/node_modules/semver/bin/semver +124 -0
  951. data/lib/node_modules/npm/node_modules/semver/foot.js +6 -0
  952. data/lib/node_modules/npm/node_modules/semver/head.js +2 -0
  953. data/lib/node_modules/npm/node_modules/semver/package.json +32 -0
  954. data/lib/node_modules/npm/node_modules/semver/semver.browser.js +1007 -0
  955. data/lib/node_modules/npm/node_modules/semver/semver.browser.js.gz +0 -0
  956. data/lib/node_modules/npm/node_modules/semver/semver.js +1011 -0
  957. data/lib/node_modules/npm/node_modules/semver/semver.min.js +1 -0
  958. data/lib/node_modules/npm/node_modules/semver/semver.min.js.gz +0 -0
  959. data/lib/node_modules/npm/node_modules/sha/LICENSE +46 -0
  960. data/lib/node_modules/npm/node_modules/sha/README.md +49 -0
  961. data/lib/node_modules/npm/node_modules/sha/index.js +120 -0
  962. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/LICENSE +27 -0
  963. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/README.md +768 -0
  964. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/duplex.js +1 -0
  965. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/float.patch +68 -0
  966. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_duplex.js +69 -0
  967. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_passthrough.js +41 -0
  968. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_readable.js +927 -0
  969. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_transform.js +205 -0
  970. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_writable.js +369 -0
  971. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/package.json +36 -0
  972. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/passthrough.js +1 -0
  973. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/readable.js +6 -0
  974. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/transform.js +1 -0
  975. data/lib/node_modules/npm/node_modules/sha/node_modules/readable-stream/writable.js +1 -0
  976. data/lib/node_modules/npm/node_modules/sha/package.json +32 -0
  977. data/lib/node_modules/npm/node_modules/slide/LICENSE +15 -0
  978. data/lib/node_modules/npm/node_modules/slide/README.md +143 -0
  979. data/lib/node_modules/npm/node_modules/slide/index.js +1 -0
  980. data/lib/node_modules/npm/node_modules/slide/lib/async-map-ordered.js +65 -0
  981. data/lib/node_modules/npm/node_modules/slide/lib/async-map.js +56 -0
  982. data/lib/node_modules/npm/node_modules/slide/lib/bind-actor.js +16 -0
  983. data/lib/node_modules/npm/node_modules/slide/lib/chain.js +20 -0
  984. data/lib/node_modules/npm/node_modules/slide/lib/slide.js +3 -0
  985. data/lib/node_modules/npm/node_modules/slide/package.json +35 -0
  986. data/lib/node_modules/npm/node_modules/tar/LICENCE +25 -0
  987. data/lib/node_modules/npm/node_modules/tar/README.md +46 -0
  988. data/lib/node_modules/npm/node_modules/tar/examples/extracter.js +11 -0
  989. data/lib/node_modules/npm/node_modules/tar/examples/reader.js +36 -0
  990. data/lib/node_modules/npm/node_modules/tar/lib/buffer-entry.js +30 -0
  991. data/lib/node_modules/npm/node_modules/tar/lib/entry-writer.js +169 -0
  992. data/lib/node_modules/npm/node_modules/tar/lib/entry.js +213 -0
  993. data/lib/node_modules/npm/node_modules/tar/lib/extended-header-writer.js +191 -0
  994. data/lib/node_modules/npm/node_modules/tar/lib/extended-header.js +140 -0
  995. data/lib/node_modules/npm/node_modules/tar/lib/extract.js +78 -0
  996. data/lib/node_modules/npm/node_modules/tar/lib/global-header-writer.js +14 -0
  997. data/lib/node_modules/npm/node_modules/tar/lib/header.js +385 -0
  998. data/lib/node_modules/npm/node_modules/tar/lib/pack.js +231 -0
  999. data/lib/node_modules/npm/node_modules/tar/lib/parse.js +270 -0
  1000. data/lib/node_modules/npm/node_modules/tar/package.json +40 -0
  1001. data/lib/node_modules/npm/node_modules/tar/tar.js +173 -0
  1002. data/lib/node_modules/npm/node_modules/text-table/LICENSE +18 -0
  1003. data/lib/node_modules/npm/node_modules/text-table/example/align.js +8 -0
  1004. data/lib/node_modules/npm/node_modules/text-table/example/center.js +8 -0
  1005. data/lib/node_modules/npm/node_modules/text-table/example/dotalign.js +9 -0
  1006. data/lib/node_modules/npm/node_modules/text-table/example/doubledot.js +11 -0
  1007. data/lib/node_modules/npm/node_modules/text-table/example/table.js +6 -0
  1008. data/lib/node_modules/npm/node_modules/text-table/index.js +86 -0
  1009. data/lib/node_modules/npm/node_modules/text-table/package.json +52 -0
  1010. data/lib/node_modules/npm/node_modules/text-table/readme.markdown +134 -0
  1011. data/lib/node_modules/npm/node_modules/uid-number/LICENCE +25 -0
  1012. data/lib/node_modules/npm/node_modules/uid-number/README.md +17 -0
  1013. data/lib/node_modules/npm/node_modules/uid-number/get-uid-gid.js +24 -0
  1014. data/lib/node_modules/npm/node_modules/uid-number/package.json +35 -0
  1015. data/lib/node_modules/npm/node_modules/uid-number/uid-number.js +54 -0
  1016. data/lib/node_modules/npm/node_modules/which/LICENSE +23 -0
  1017. data/lib/node_modules/npm/node_modules/which/README.md +5 -0
  1018. data/lib/node_modules/npm/node_modules/which/bin/which +14 -0
  1019. data/lib/node_modules/npm/node_modules/which/package.json +34 -0
  1020. data/lib/node_modules/npm/node_modules/which/which.js +104 -0
  1021. data/lib/node_modules/npm/package.json +155 -0
  1022. data/lib/node_modules/npm/scripts/clean-old.sh +165 -0
  1023. data/lib/node_modules/npm/scripts/doc-build.sh +84 -0
  1024. data/lib/node_modules/npm/scripts/index-build.js +62 -0
  1025. data/lib/node_modules/npm/scripts/install.sh +313 -0
  1026. data/lib/node_modules/npm/scripts/release.sh +36 -0
  1027. data/lib/node_modules/npm/scripts/relocate.sh +26 -0
  1028. metadata +1052 -36
  1029. checksums.yaml +0 -7
@@ -0,0 +1,138 @@
1
+
2
+ module.exports = adduser
3
+
4
+ var log = require("npmlog")
5
+ , npm = require("./npm.js")
6
+ , registry = npm.registry
7
+ , read = require("read")
8
+ , userValidate = require("npm-user-validate")
9
+ , crypto
10
+
11
+ try {
12
+ crypto = process.binding("crypto") && require("crypto")
13
+ } catch (ex) {}
14
+
15
+ adduser.usage = "npm adduser\nThen enter stuff at the prompts"
16
+
17
+ function adduser (args, cb) {
18
+ if (!crypto) return cb(new Error(
19
+ "You must compile node with ssl support to use the adduser feature"))
20
+
21
+ var c = { u : npm.config.get("username") || ""
22
+ , p : npm.config.get("_password") || ""
23
+ , e : npm.config.get("email") || ""
24
+ }
25
+ , changed = false
26
+ , u = {}
27
+ , fns = [readUsername, readPassword, readEmail, save]
28
+
29
+ loop()
30
+ function loop (er) {
31
+ if (er) return cb(er)
32
+ var fn = fns.shift()
33
+ if (fn) return fn(c, u, loop)
34
+ cb()
35
+ }
36
+ }
37
+
38
+ function readUsername (c, u, cb) {
39
+ var v = userValidate.username
40
+ read({prompt: "Username: ", default: c.u || ""}, function (er, un) {
41
+ if (er) {
42
+ return cb(er.message === "cancelled" ? er.message : er)
43
+ }
44
+
45
+ // make sure it's valid. we have to do this here, because
46
+ // couchdb will only ever say "bad password" with a 401 when
47
+ // you try to PUT a _users record that the validate_doc_update
48
+ // rejects for *any* reason.
49
+
50
+ if (!un) {
51
+ return readUsername(c, u, cb)
52
+ }
53
+
54
+ var error = v(un)
55
+ if (error) {
56
+ log.warn(error.message)
57
+ return readUsername(c, u, cb)
58
+ }
59
+
60
+ c.changed = c.u !== un
61
+ u.u = un
62
+ cb(er)
63
+ })
64
+ }
65
+
66
+ function readPassword (c, u, cb) {
67
+ var v = userValidate.pw
68
+
69
+ if (!c.changed) {
70
+ u.p = c.p
71
+ return cb()
72
+ }
73
+ read({prompt: "Password: ", silent: true}, function (er, pw) {
74
+ if (er) {
75
+ return cb(er.message === "cancelled" ? er.message : er)
76
+ }
77
+
78
+ if (!pw) {
79
+ return readPassword(c, u, cb)
80
+ }
81
+
82
+ var error = v(pw)
83
+ if (error) {
84
+ log.warn(error.message)
85
+ return readPassword(c, u, cb)
86
+ }
87
+
88
+ u.p = pw
89
+ cb(er)
90
+ })
91
+ }
92
+
93
+ function readEmail (c, u, cb) {
94
+ var v = userValidate.email
95
+ var r = { prompt: "Email: (this IS public) ", default: c.e || "" }
96
+ read(r, function (er, em) {
97
+ if (er) {
98
+ return cb(er.message === "cancelled" ? er.message : er)
99
+ }
100
+
101
+ if (!em) {
102
+ return readEmail(c, u, cb)
103
+ }
104
+
105
+ var error = v(em)
106
+ if (error) {
107
+ log.warn(error.message)
108
+ return readEmail(c, u, cb)
109
+ }
110
+
111
+ u.e = em
112
+ cb(er)
113
+ })
114
+ }
115
+
116
+ function save (c, u, cb) {
117
+ if (c.changed) {
118
+ delete registry.auth
119
+ delete registry.username
120
+ delete registry.password
121
+ registry.username = u.u
122
+ registry.password = u.p
123
+ }
124
+
125
+ // save existing configs, but yank off for this PUT
126
+ registry.adduser(u.u, u.p, u.e, function (er) {
127
+ if (er) return cb(er)
128
+ registry.username = u.u
129
+ registry.password = u.p
130
+ registry.email = u.e
131
+ npm.config.set("username", u.u, "user")
132
+ npm.config.set("_password", u.p, "user")
133
+ npm.config.set("email", u.e, "user")
134
+ npm.config.del("_token", "user")
135
+ log.info("adduser", "Authorized user %s", u.u)
136
+ npm.config.save("user", cb)
137
+ })
138
+ }
@@ -0,0 +1,18 @@
1
+ module.exports = bin
2
+
3
+ var npm = require("./npm.js")
4
+
5
+ bin.usage = "npm bin\nnpm bin -g\n(just prints the bin folder)"
6
+
7
+ function bin (args, silent, cb) {
8
+ if (typeof cb !== "function") cb = silent, silent = false
9
+ var b = npm.bin
10
+ , PATH = (process.env.PATH || "").split(":")
11
+
12
+ if (!silent) console.log(b)
13
+ process.nextTick(cb.bind(this, null, b))
14
+
15
+ if (npm.config.get("global") && PATH.indexOf(b) === -1) {
16
+ npm.config.get("logstream").write("(not in PATH env variable)\n")
17
+ }
18
+ }
@@ -0,0 +1,61 @@
1
+
2
+ module.exports = bugs
3
+
4
+ bugs.usage = "npm bugs <pkgname>"
5
+
6
+ var npm = require("./npm.js")
7
+ , registry = npm.registry
8
+ , log = require("npmlog")
9
+ , opener = require("opener")
10
+ , path = require("path")
11
+ , readJson = require("read-package-json")
12
+ , fs = require("fs")
13
+
14
+ bugs.completion = function (opts, cb) {
15
+ if (opts.conf.argv.remain.length > 2) return cb()
16
+ registry.get("/-/short", 60000, function (er, list) {
17
+ return cb(null, list || [])
18
+ })
19
+ }
20
+
21
+ function bugs (args, cb) {
22
+ var n = args.length && args[0].split("@").shift() || '.'
23
+ fs.stat(n, function (er, s) {
24
+ if (er && er.code === "ENOENT") return callRegistry(n, cb)
25
+ else if (er) return cb (er)
26
+ if (!s.isDirectory()) return callRegistry(n, cb)
27
+ readJson(path.resolve(n, "package.json"), function(er, d) {
28
+ if (er) return cb(er)
29
+ getUrlAndOpen(d, cb)
30
+ })
31
+ })
32
+ }
33
+
34
+ function getUrlAndOpen (d, cb) {
35
+ var bugs = d.bugs
36
+ , repo = d.repository || d.repositories
37
+ , url
38
+ if (bugs) {
39
+ url = (typeof url === "string") ? bugs : bugs.url
40
+ } else if (repo) {
41
+ if (Array.isArray(repo)) repo = repo.shift()
42
+ if (repo.hasOwnProperty("url")) repo = repo.url
43
+ log.verbose("repository", repo)
44
+ if (bugs && bugs.match(/^(https?:\/\/|git(:\/\/|@))github.com/)) {
45
+ url = bugs.replace(/^git(@|:\/\/)/, "https://")
46
+ .replace(/^https?:\/\/github.com:/, "https://github.com/")
47
+ .replace(/\.git$/, '')+"/issues"
48
+ }
49
+ }
50
+ if (!url) {
51
+ url = "https://npmjs.org/package/" + d.name
52
+ }
53
+ opener(url, { command: npm.config.get("browser") }, cb)
54
+ }
55
+
56
+ function callRegistry (n, cb) {
57
+ registry.get(n + "/latest", 3600, function (er, d) {
58
+ if (er) return cb(er)
59
+ getUrlAndOpen (d, cb)
60
+ })
61
+ }
@@ -0,0 +1,228 @@
1
+ // npm build command
2
+
3
+ // everything about the installation after the creation of
4
+ // the .npm/{name}/{version}/package folder.
5
+ // linking the modules into the npm.root,
6
+ // resolving dependencies, etc.
7
+
8
+ // This runs AFTER install or link are completed.
9
+
10
+ var npm = require("./npm.js")
11
+ , log = require("npmlog")
12
+ , chain = require("slide").chain
13
+ , fs = require("graceful-fs")
14
+ , path = require("path")
15
+ , lifecycle = require("./utils/lifecycle.js")
16
+ , readJson = require("read-package-json")
17
+ , link = require("./utils/link.js")
18
+ , linkIfExists = link.ifExists
19
+ , cmdShim = require("cmd-shim")
20
+ , cmdShimIfExists = cmdShim.ifExists
21
+ , asyncMap = require("slide").asyncMap
22
+
23
+ module.exports = build
24
+ build.usage = "npm build <folder>\n(this is plumbing)"
25
+
26
+ build._didBuild = {}
27
+ build._noLC = {}
28
+ function build (args, global, didPre, didRB, cb) {
29
+ if (typeof cb !== "function") cb = didRB, didRB = false
30
+ if (typeof cb !== "function") cb = didPre, didPre = false
31
+ if (typeof cb !== "function") {
32
+ cb = global, global = npm.config.get("global")
33
+ }
34
+ // it'd be nice to asyncMap these, but actually, doing them
35
+ // in parallel generally munges up the output from node-waf
36
+ var builder = build_(global, didPre, didRB)
37
+ chain(args.map(function (arg) { return function (cb) {
38
+ builder(arg, cb)
39
+ }}), cb)
40
+ }
41
+
42
+ function build_ (global, didPre, didRB) { return function (folder, cb) {
43
+ folder = path.resolve(folder)
44
+ build._didBuild[folder] = true
45
+ log.info("build", folder)
46
+ readJson(path.resolve(folder, "package.json"), function (er, pkg) {
47
+ if (er) return cb(er)
48
+ chain
49
+ ( [ !didPre && [lifecycle, pkg, "preinstall", folder]
50
+ , [linkStuff, pkg, folder, global, didRB]
51
+ , pkg.name === "npm" && [writeBuiltinConf, folder]
52
+ , didPre !== build._noLC && [lifecycle, pkg, "install", folder]
53
+ , didPre !== build._noLC && [lifecycle, pkg, "postinstall", folder]
54
+ , didPre !== build._noLC
55
+ && npm.config.get("npat")
56
+ && [lifecycle, pkg, "test", folder] ]
57
+ , cb )
58
+ })
59
+ }}
60
+
61
+ function writeBuiltinConf (folder, cb) {
62
+ // the builtin config is "sticky". Any time npm installs itself,
63
+ // it puts its builtin config file there, as well.
64
+ if (!npm.config.usingBuiltin
65
+ || folder !== path.dirname(__dirname)) {
66
+ return cb()
67
+ }
68
+ npm.config.save("builtin", cb)
69
+ }
70
+
71
+ function linkStuff (pkg, folder, global, didRB, cb) {
72
+ // allow to opt out of linking binaries.
73
+ if (npm.config.get("bin-links") === false) return cb()
74
+
75
+ // if it's global, and folder is in {prefix}/node_modules,
76
+ // then bins are in {prefix}/bin
77
+ // otherwise, then bins are in folder/../.bin
78
+ var parent = path.dirname(folder)
79
+ , gnm = global && npm.globalDir
80
+ , top = parent === npm.dir
81
+ , gtop = parent === gnm
82
+
83
+ log.verbose("linkStuff", [global, gnm, gtop, parent])
84
+ log.info("linkStuff", pkg._id)
85
+
86
+ shouldWarn(pkg, folder, global, function() {
87
+ asyncMap( [linkBins, linkMans, !didRB && rebuildBundles]
88
+ , function (fn, cb) {
89
+ if (!fn) return cb()
90
+ log.verbose(fn.name, pkg._id)
91
+ fn(pkg, folder, parent, gtop, cb)
92
+ }, cb)
93
+ })
94
+ }
95
+
96
+ function shouldWarn(pkg, folder, global, cb) {
97
+ var parent = path.dirname(folder)
98
+ , top = parent === npm.dir
99
+ , cwd = process.cwd()
100
+
101
+ readJson(path.resolve(cwd, "package.json"), function(er, topPkg) {
102
+ if (er) return cb(er)
103
+
104
+ var linkedPkg = path.basename(cwd)
105
+ , currentPkg = path.basename(folder)
106
+
107
+ // current searched package is the linked package on first call
108
+ if (linkedPkg !== currentPkg) {
109
+
110
+ if (!topPkg.dependencies) return cb()
111
+
112
+ // don't generate a warning if it's listed in dependencies
113
+ if (Object.keys(topPkg.dependencies).indexOf(currentPkg) === -1) {
114
+
115
+ if (top && pkg.preferGlobal && !global) {
116
+ log.warn("prefer global", pkg._id + " should be installed with -g")
117
+ }
118
+ }
119
+ }
120
+
121
+ cb()
122
+ })
123
+ }
124
+
125
+ function rebuildBundles (pkg, folder, parent, gtop, cb) {
126
+ if (!npm.config.get("rebuild-bundle")) return cb()
127
+
128
+ var deps = Object.keys(pkg.dependencies || {})
129
+ .concat(Object.keys(pkg.devDependencies || {}))
130
+ , bundles = pkg.bundleDependencies || pkg.bundledDependencies || []
131
+
132
+ fs.readdir(path.resolve(folder, "node_modules"), function (er, files) {
133
+ // error means no bundles
134
+ if (er) return cb()
135
+
136
+ log.verbose("rebuildBundles", files)
137
+ // don't asyncMap these, because otherwise build script output
138
+ // gets interleaved and is impossible to read
139
+ chain(files.filter(function (file) {
140
+ // rebuild if:
141
+ // not a .folder, like .bin or .hooks
142
+ return !file.match(/^[\._-]/)
143
+ // not some old 0.x style bundle
144
+ && file.indexOf("@") === -1
145
+ // either not a dep, or explicitly bundled
146
+ && (deps.indexOf(file) === -1 || bundles.indexOf(file) !== -1)
147
+ }).map(function (file) {
148
+ file = path.resolve(folder, "node_modules", file)
149
+ return function (cb) {
150
+ if (build._didBuild[file]) return cb()
151
+ log.verbose("rebuild bundle", file)
152
+ // if file is not a package dir, then don't do it.
153
+ fs.lstat(path.resolve(file, "package.json"), function (er, st) {
154
+ if (er) return cb()
155
+ build_(false)(file, cb)
156
+ })
157
+ }}), cb)
158
+ })
159
+ }
160
+
161
+ function linkBins (pkg, folder, parent, gtop, cb) {
162
+ if (!pkg.bin || !gtop && path.basename(parent) !== "node_modules") {
163
+ return cb()
164
+ }
165
+ var binRoot = gtop ? npm.globalBin
166
+ : path.resolve(parent, ".bin")
167
+ log.verbose("link bins", [pkg.bin, binRoot, gtop])
168
+
169
+ asyncMap(Object.keys(pkg.bin), function (b, cb) {
170
+ linkBin( path.resolve(folder, pkg.bin[b])
171
+ , path.resolve(binRoot, b)
172
+ , gtop && folder
173
+ , function (er) {
174
+ if (er) return cb(er)
175
+ // bins should always be executable.
176
+ // XXX skip chmod on windows?
177
+ var src = path.resolve(folder, pkg.bin[b])
178
+ fs.chmod(src, npm.modes.exec, function (er) {
179
+ if (er && er.code === "ENOENT" && npm.config.get("ignore-scripts")) {
180
+ return cb()
181
+ }
182
+ if (er || !gtop) return cb(er)
183
+ var dest = path.resolve(binRoot, b)
184
+ , out = npm.config.get("parseable")
185
+ ? dest + "::" + src + ":BINFILE"
186
+ : dest + " -> " + src
187
+ console.log(out)
188
+ cb()
189
+ })
190
+ })
191
+ }, cb)
192
+ }
193
+
194
+ function linkBin (from, to, gently, cb) {
195
+ if (process.platform !== "win32") {
196
+ return linkIfExists(from, to, gently, cb)
197
+ } else {
198
+ return cmdShimIfExists(from, to, cb)
199
+ }
200
+ }
201
+
202
+ function linkMans (pkg, folder, parent, gtop, cb) {
203
+ if (!pkg.man || !gtop || process.platform === "win32") return cb()
204
+
205
+ var manRoot = path.resolve(npm.config.get("prefix"), "share", "man")
206
+
207
+ // make sure that the mans are unique.
208
+ // otherwise, if there are dupes, it'll fail with EEXIST
209
+ var set = pkg.man.reduce(function (acc, man) {
210
+ acc[path.basename(man)] = man
211
+ return acc
212
+ }, {})
213
+ pkg.man = pkg.man.filter(function (man) {
214
+ return set[path.basename(man)] === man
215
+ })
216
+
217
+ asyncMap(pkg.man, function (man, cb) {
218
+ if (typeof man !== "string") return cb()
219
+ var parseMan = man.match(/(.*\.([0-9]+)(\.gz)?)$/)
220
+ , stem = parseMan[1]
221
+ , sxn = parseMan[2]
222
+ , gz = parseMan[3] || ""
223
+ , bn = path.basename(stem)
224
+ , manDest = path.join(manRoot, "man" + sxn, bn)
225
+
226
+ linkIfExists(man, manDest, gtop && folder, cb)
227
+ }, cb)
228
+ }
@@ -0,0 +1,1318 @@
1
+ // XXX lib/utils/tar.js and this file need to be rewritten.
2
+
3
+ // URL-to-cache folder mapping:
4
+ // : -> !
5
+ // @ -> _
6
+ // http://registry.npmjs.org/foo/version -> cache/http!/...
7
+ //
8
+
9
+ /*
10
+ fetching a url:
11
+ 1. Check for url in inFlightUrls. If present, add cb, and return.
12
+ 2. create inFlightURL list
13
+ 3. Acquire lock at {cache}/{sha(url)}.lock
14
+ retries = {cache-lock-retries, def=3}
15
+ stale = {cache-lock-stale, def=30000}
16
+ wait = {cache-lock-wait, def=100}
17
+ 4. if lock can't be acquired, then fail
18
+ 5. fetch url, clear lock, call cbs
19
+
20
+ cache folders:
21
+ 1. urls: http!/server.com/path/to/thing
22
+ 2. c:\path\to\thing: file!/c!/path/to/thing
23
+ 3. /path/to/thing: file!/path/to/thing
24
+ 4. git@ private: git_github.com!npm/npm
25
+ 5. git://public: git!/github.com/npm/npm
26
+ 6. git+blah:// git-blah!/server.com/foo/bar
27
+
28
+ adding a folder:
29
+ 1. tar into tmp/random/package.tgz
30
+ 2. untar into tmp/random/contents/package, stripping one dir piece
31
+ 3. tar tmp/random/contents/package to cache/n/v/package.tgz
32
+ 4. untar cache/n/v/package.tgz into cache/n/v/package
33
+ 5. rm tmp/random
34
+
35
+ Adding a url:
36
+ 1. fetch to tmp/random/package.tgz
37
+ 2. goto folder(2)
38
+
39
+ adding a name@version:
40
+ 1. registry.get(name/version)
41
+ 2. if response isn't 304, add url(dist.tarball)
42
+
43
+ adding a name@range:
44
+ 1. registry.get(name)
45
+ 2. Find a version that satisfies
46
+ 3. add name@version
47
+
48
+ adding a local tarball:
49
+ 1. untar to tmp/random/{blah}
50
+ 2. goto folder(2)
51
+ */
52
+
53
+ exports = module.exports = cache
54
+ cache.read = read
55
+ cache.clean = clean
56
+ cache.unpack = unpack
57
+ cache.lock = lock
58
+ cache.unlock = unlock
59
+
60
+ var mkdir = require("mkdirp")
61
+ , spawn = require("child_process").spawn
62
+ , exec = require("child_process").execFile
63
+ , once = require("once")
64
+ , fetch = require("./utils/fetch.js")
65
+ , npm = require("./npm.js")
66
+ , fs = require("graceful-fs")
67
+ , rm = require("./utils/gently-rm.js")
68
+ , readJson = require("read-package-json")
69
+ , registry = npm.registry
70
+ , log = require("npmlog")
71
+ , path = require("path")
72
+ , sha = require("sha")
73
+ , asyncMap = require("slide").asyncMap
74
+ , semver = require("semver")
75
+ , tar = require("./utils/tar.js")
76
+ , fileCompletion = require("./utils/completion/file-completion.js")
77
+ , url = require("url")
78
+ , chownr = require("chownr")
79
+ , lockFile = require("lockfile")
80
+ , crypto = require("crypto")
81
+ , retry = require("retry")
82
+ , zlib = require("zlib")
83
+ , chmodr = require("chmodr")
84
+ , which = require("which")
85
+ , isGitUrl = require("./utils/is-git-url.js")
86
+ , pathIsInside = require("path-is-inside")
87
+
88
+ cache.usage = "npm cache add <tarball file>"
89
+ + "\nnpm cache add <folder>"
90
+ + "\nnpm cache add <tarball url>"
91
+ + "\nnpm cache add <git url>"
92
+ + "\nnpm cache add <name>@<version>"
93
+ + "\nnpm cache ls [<path>]"
94
+ + "\nnpm cache clean [<pkg>[@<version>]]"
95
+
96
+ cache.completion = function (opts, cb) {
97
+
98
+ var argv = opts.conf.argv.remain
99
+ if (argv.length === 2) {
100
+ return cb(null, ["add", "ls", "clean"])
101
+ }
102
+
103
+ switch (argv[2]) {
104
+ case "clean":
105
+ case "ls":
106
+ // cache and ls are easy, because the completion is
107
+ // what ls_ returns anyway.
108
+ // just get the partial words, minus the last path part
109
+ var p = path.dirname(opts.partialWords.slice(3).join("/"))
110
+ if (p === ".") p = ""
111
+ return ls_(p, 2, cb)
112
+ case "add":
113
+ // Same semantics as install and publish.
114
+ return npm.commands.install.completion(opts, cb)
115
+ }
116
+ }
117
+
118
+ function cache (args, cb) {
119
+ var cmd = args.shift()
120
+ switch (cmd) {
121
+ case "rm": case "clear": case "clean": return clean(args, cb)
122
+ case "list": case "sl": case "ls": return ls(args, cb)
123
+ case "add": return add(args, cb)
124
+ default: return cb(new Error(
125
+ "Invalid cache action: "+cmd))
126
+ }
127
+ }
128
+
129
+ // if the pkg and ver are in the cache, then
130
+ // just do a readJson and return.
131
+ // if they're not, then fetch them from the registry.
132
+ function read (name, ver, forceBypass, cb) {
133
+ if (typeof cb !== "function") cb = forceBypass, forceBypass = true
134
+ var jsonFile = path.join(npm.cache, name, ver, "package", "package.json")
135
+ function c (er, data) {
136
+ if (data) deprCheck(data)
137
+ return cb(er, data)
138
+ }
139
+
140
+ if (forceBypass && npm.config.get("force")) {
141
+ log.verbose("using force", "skipping cache")
142
+ return addNamed(name, ver, c)
143
+ }
144
+
145
+ readJson(jsonFile, function (er, data) {
146
+ er = needName(er, data)
147
+ er = needVersion(er, data)
148
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
149
+ if (er) return addNamed(name, ver, c)
150
+ deprCheck(data)
151
+ c(er, data)
152
+ })
153
+ }
154
+
155
+ // npm cache ls [<path>]
156
+ function ls (args, cb) {
157
+ args = args.join("/").split("@").join("/")
158
+ if (args.substr(-1) === "/") args = args.substr(0, args.length - 1)
159
+ var prefix = npm.config.get("cache")
160
+ if (0 === prefix.indexOf(process.env.HOME)) {
161
+ prefix = "~" + prefix.substr(process.env.HOME.length)
162
+ }
163
+ ls_(args, npm.config.get("depth"), function (er, files) {
164
+ console.log(files.map(function (f) {
165
+ return path.join(prefix, f)
166
+ }).join("\n").trim())
167
+ cb(er, files)
168
+ })
169
+ }
170
+
171
+ // Calls cb with list of cached pkgs matching show.
172
+ function ls_ (req, depth, cb) {
173
+ return fileCompletion(npm.cache, req, depth, cb)
174
+ }
175
+
176
+ // npm cache clean [<path>]
177
+ function clean (args, cb) {
178
+ if (!cb) cb = args, args = []
179
+ if (!args) args = []
180
+ args = args.join("/").split("@").join("/")
181
+ if (args.substr(-1) === "/") args = args.substr(0, args.length - 1)
182
+ var f = path.join(npm.cache, path.normalize(args))
183
+ if (f === npm.cache) {
184
+ fs.readdir(npm.cache, function (er, files) {
185
+ if (er) return cb()
186
+ asyncMap( files.filter(function (f) {
187
+ return npm.config.get("force") || f !== "-"
188
+ }).map(function (f) {
189
+ return path.join(npm.cache, f)
190
+ })
191
+ , rm, cb )
192
+ })
193
+ } else rm(path.join(npm.cache, path.normalize(args)), cb)
194
+ }
195
+
196
+ // npm cache add <tarball-url>
197
+ // npm cache add <pkg> <ver>
198
+ // npm cache add <tarball>
199
+ // npm cache add <folder>
200
+ cache.add = function (pkg, ver, scrub, cb) {
201
+ if (typeof cb !== "function") cb = scrub, scrub = false
202
+ if (typeof cb !== "function") cb = ver, ver = null
203
+ if (scrub) {
204
+ return clean([], function (er) {
205
+ if (er) return cb(er)
206
+ add([pkg, ver], cb)
207
+ })
208
+ }
209
+ log.verbose("cache add", [pkg, ver])
210
+ return add([pkg, ver], cb)
211
+ }
212
+
213
+ function add (args, cb) {
214
+ // this is hot code. almost everything passes through here.
215
+ // the args can be any of:
216
+ // ["url"]
217
+ // ["pkg", "version"]
218
+ // ["pkg@version"]
219
+ // ["pkg", "url"]
220
+ // This is tricky, because urls can contain @
221
+ // Also, in some cases we get [name, null] rather
222
+ // that just a single argument.
223
+
224
+ var usage = "Usage:\n"
225
+ + " npm cache add <tarball-url>\n"
226
+ + " npm cache add <pkg>@<ver>\n"
227
+ + " npm cache add <tarball>\n"
228
+ + " npm cache add <folder>\n"
229
+ , name
230
+ , spec
231
+
232
+ if (args[1] === undefined) args[1] = null
233
+
234
+ // at this point the args length must ==2
235
+ if (args[1] !== null) {
236
+ name = args[0]
237
+ spec = args[1]
238
+ } else if (args.length === 2) {
239
+ spec = args[0]
240
+ }
241
+
242
+ log.verbose("cache add", "name=%j spec=%j args=%j", name, spec, args)
243
+
244
+
245
+ if (!name && !spec) return cb(usage)
246
+
247
+ // see if the spec is a url
248
+ // otherwise, treat as name@version
249
+ var p = url.parse(spec) || {}
250
+ log.verbose("parsed url", p)
251
+
252
+ // If there's a /, and it's a path, then install the path.
253
+ // If not, and there's a @, it could be that we got name@http://blah
254
+ // in that case, we will not have a protocol now, but if we
255
+ // split and check, we will.
256
+ if (!name && !p.protocol) {
257
+ if (spec.indexOf("/") !== -1 ||
258
+ process.platform === "win32" && spec.indexOf("\\") !== -1) {
259
+ return maybeFile(spec, p, cb)
260
+ } else if (spec.indexOf("@") !== -1) {
261
+ return maybeAt(spec, cb)
262
+ }
263
+ }
264
+
265
+ add_(name, spec, p, cb)
266
+ }
267
+
268
+ function maybeFile (spec, p, cb) {
269
+ fs.stat(spec, function (er, stat) {
270
+ if (!er) {
271
+ // definitely a local thing
272
+ addLocal(spec, cb)
273
+ } else if (er && spec.indexOf("@") !== -1) {
274
+ // bar@baz/loofa
275
+ maybeAt(spec, cb)
276
+ } else {
277
+ // Already know it's not a url, so must be local
278
+ addLocal(spec, cb)
279
+ }
280
+ })
281
+ }
282
+
283
+ function maybeAt (spec, cb) {
284
+ var tmp = spec.split("@")
285
+
286
+ // split name@2.3.4 only if name is a valid package name,
287
+ // don't split in case of "./test@example.com/" (local path)
288
+ var name = tmp.shift()
289
+ spec = tmp.join("@")
290
+ return add([name, spec], cb)
291
+ }
292
+
293
+ function add_ (name, spec, p, cb) {
294
+ switch (p.protocol) {
295
+ case "http:":
296
+ case "https:":
297
+ return addRemoteTarball(spec, null, name, cb)
298
+
299
+ default:
300
+ if (isGitUrl(p))
301
+ return addRemoteGit(spec, p, name, false, cb)
302
+
303
+ // if we have a name and a spec, then try name@spec
304
+ // if not, then try just spec (which may try name@"" if not found)
305
+ if (name) {
306
+ addNamed(name, spec, cb)
307
+ } else {
308
+ addLocal(spec, cb)
309
+ }
310
+ }
311
+ }
312
+
313
+ function fetchAndShaCheck (u, tmp, shasum, cb) {
314
+ fetch(u, tmp, function (er, response) {
315
+ if (er) {
316
+ log.error("fetch failed", u)
317
+ return cb(er, response)
318
+ }
319
+ if (!shasum) return cb(null, response)
320
+ // validate that the url we just downloaded matches the expected shasum.
321
+ sha.check(tmp, shasum, function (er) {
322
+ if (er != null && er.message) {
323
+ // add original filename for better debuggability
324
+ er.message = er.message + '\n' + 'From: ' + u
325
+ }
326
+ return cb(er, response, shasum)
327
+ })
328
+ })
329
+ }
330
+
331
+ // Only have a single download action at once for a given url
332
+ // additional calls stack the callbacks.
333
+ var inFlightURLs = {}
334
+ function addRemoteTarball (u, shasum, name, cb_) {
335
+ if (typeof cb_ !== "function") cb_ = name, name = ""
336
+ if (typeof cb_ !== "function") cb_ = shasum, shasum = null
337
+
338
+ if (!inFlightURLs[u]) inFlightURLs[u] = []
339
+ var iF = inFlightURLs[u]
340
+ iF.push(cb_)
341
+ if (iF.length > 1) return
342
+
343
+ function cb (er, data) {
344
+ if (data) {
345
+ data._from = u
346
+ data._resolved = u
347
+ }
348
+ unlock(u, function () {
349
+ var c
350
+ while (c = iF.shift()) c(er, data)
351
+ delete inFlightURLs[u]
352
+ })
353
+ }
354
+
355
+ var tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
356
+
357
+ lock(u, function (er) {
358
+ if (er) return cb(er)
359
+
360
+ log.verbose("addRemoteTarball", [u, shasum])
361
+ mkdir(path.dirname(tmp), function (er) {
362
+ if (er) return cb(er)
363
+ addRemoteTarball_(u, tmp, shasum, done)
364
+ })
365
+ })
366
+
367
+ function done (er, resp, shasum) {
368
+ if (er) return cb(er)
369
+ addLocalTarball(tmp, name, shasum, cb)
370
+ }
371
+ }
372
+
373
+ function addRemoteTarball_(u, tmp, shasum, cb) {
374
+ // Tuned to spread 3 attempts over about a minute.
375
+ // See formula at <https://github.com/tim-kos/node-retry>.
376
+ var operation = retry.operation
377
+ ( { retries: npm.config.get("fetch-retries")
378
+ , factor: npm.config.get("fetch-retry-factor")
379
+ , minTimeout: npm.config.get("fetch-retry-mintimeout")
380
+ , maxTimeout: npm.config.get("fetch-retry-maxtimeout") })
381
+
382
+ operation.attempt(function (currentAttempt) {
383
+ log.info("retry", "fetch attempt " + currentAttempt
384
+ + " at " + (new Date()).toLocaleTimeString())
385
+ fetchAndShaCheck(u, tmp, shasum, function (er, response, shasum) {
386
+ // Only retry on 408, 5xx or no `response`.
387
+ var sc = response && response.statusCode
388
+ var statusRetry = !sc || (sc === 408 || sc >= 500)
389
+ if (er && statusRetry && operation.retry(er)) {
390
+ log.info("retry", "will retry, error on last attempt: " + er)
391
+ return
392
+ }
393
+ cb(er, response, shasum)
394
+ })
395
+ })
396
+ }
397
+
398
+ // 1. cacheDir = path.join(cache,'_git-remotes',sha1(u))
399
+ // 2. checkGitDir(cacheDir) ? 4. : 3. (rm cacheDir if necessary)
400
+ // 3. git clone --mirror u cacheDir
401
+ // 4. cd cacheDir && git fetch -a origin
402
+ // 5. git archive /tmp/random.tgz
403
+ // 6. addLocalTarball(/tmp/random.tgz) <gitref> --format=tar --prefix=package/
404
+ // silent flag is used if this should error quietly
405
+ function addRemoteGit (u, parsed, name, silent, cb_) {
406
+ if (typeof cb_ !== "function") cb_ = name, name = null
407
+
408
+ if (!inFlightURLs[u]) inFlightURLs[u] = []
409
+ var iF = inFlightURLs[u]
410
+ iF.push(cb_)
411
+ if (iF.length > 1) return
412
+
413
+ // git is so tricky!
414
+ // if the path is like ssh://foo:22/some/path then it works, but
415
+ // it needs the ssh://
416
+ // If the path is like ssh://foo:some/path then it works, but
417
+ // only if you remove the ssh://
418
+ var origUrl = u
419
+ u = u.replace(/^git\+/, "")
420
+ .replace(/#.*$/, "")
421
+
422
+ // ssh paths that are scp-style urls don't need the ssh://
423
+ if (parsed.pathname.match(/^\/?:/)) {
424
+ u = u.replace(/^ssh:\/\//, "")
425
+ }
426
+
427
+ function cb (er, data) {
428
+ unlock(u, function () {
429
+ var c
430
+ while (c = iF.shift()) c(er, data)
431
+ delete inFlightURLs[origUrl]
432
+ })
433
+ }
434
+
435
+ lock(u, function (er) {
436
+ if (er) return cb(er)
437
+
438
+ // figure out what we should check out.
439
+ var co = parsed.hash && parsed.hash.substr(1) || "master"
440
+
441
+ var v = crypto.createHash("sha1").update(u).digest("hex").slice(0, 8)
442
+ v = u.replace(/[^a-zA-Z0-9]+/g, '-') + '-' + v
443
+
444
+ log.verbose("addRemoteGit", [u, co])
445
+
446
+ var p = path.join(npm.config.get("cache"), "_git-remotes", v)
447
+
448
+ checkGitDir(p, u, co, origUrl, silent, function(er, data) {
449
+ chmodr(p, npm.modes.file, function(erChmod) {
450
+ if (er) return cb(er, data)
451
+ return cb(erChmod, data)
452
+ })
453
+ })
454
+ })
455
+ }
456
+
457
+ function checkGitDir (p, u, co, origUrl, silent, cb) {
458
+ fs.stat(p, function (er, s) {
459
+ if (er) return cloneGitRemote(p, u, co, origUrl, silent, cb)
460
+ if (!s.isDirectory()) return rm(p, function (er){
461
+ if (er) return cb(er)
462
+ cloneGitRemote(p, u, co, origUrl, silent, cb)
463
+ })
464
+
465
+ var git = npm.config.get("git")
466
+ var args = [ "config", "--get", "remote.origin.url" ]
467
+ var env = gitEnv()
468
+
469
+ // check for git
470
+ which(git, function (err) {
471
+ if (err) {
472
+ err.code = "ENOGIT"
473
+ return cb(err)
474
+ }
475
+ exec(git, args, {cwd: p, env: env}, function (er, stdout, stderr) {
476
+ stdoutTrimmed = (stdout + "\n" + stderr).trim()
477
+ if (er || u !== stdout.trim()) {
478
+ log.warn( "`git config --get remote.origin.url` returned "
479
+ + "wrong result ("+u+")", stdoutTrimmed )
480
+ return rm(p, function (er){
481
+ if (er) return cb(er)
482
+ cloneGitRemote(p, u, co, origUrl, silent, cb)
483
+ })
484
+ }
485
+ log.verbose("git remote.origin.url", stdoutTrimmed)
486
+ archiveGitRemote(p, u, co, origUrl, cb)
487
+ })
488
+ })
489
+ })
490
+ }
491
+
492
+ function cloneGitRemote (p, u, co, origUrl, silent, cb) {
493
+ mkdir(p, function (er) {
494
+ if (er) return cb(er)
495
+
496
+ var git = npm.config.get("git")
497
+ var args = [ "clone", "--mirror", u, p ]
498
+ var env = gitEnv()
499
+
500
+ // check for git
501
+ which(git, function (err) {
502
+ if (err) {
503
+ err.code = "ENOGIT"
504
+ return cb(err)
505
+ }
506
+ exec(git, args, {cwd: p, env: env}, function (er, stdout, stderr) {
507
+ stdout = (stdout + "\n" + stderr).trim()
508
+ if (er) {
509
+ if (silent) {
510
+ log.verbose("git clone " + u, stdout)
511
+ } else {
512
+ log.error("git clone " + u, stdout)
513
+ }
514
+ return cb(er)
515
+ }
516
+ log.verbose("git clone " + u, stdout)
517
+ archiveGitRemote(p, u, co, origUrl, cb)
518
+ })
519
+ })
520
+ })
521
+ }
522
+
523
+ function archiveGitRemote (p, u, co, origUrl, cb) {
524
+ var git = npm.config.get("git")
525
+ var archive = [ "fetch", "-a", "origin" ]
526
+ var resolve = [ "rev-list", "-n1", co ]
527
+ var env = gitEnv()
528
+
529
+ var errState = null
530
+ var n = 0
531
+ var resolved = null
532
+ var tmp
533
+
534
+ exec(git, archive, {cwd: p, env: env}, function (er, stdout, stderr) {
535
+ stdout = (stdout + "\n" + stderr).trim()
536
+ if (er) {
537
+ log.error("git fetch -a origin ("+u+")", stdout)
538
+ return cb(er)
539
+ }
540
+ log.verbose("git fetch -a origin ("+u+")", stdout)
541
+ tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
542
+ verifyOwnership()
543
+ })
544
+
545
+ function verifyOwnership() {
546
+ if (process.platform === "win32") {
547
+ log.silly("verifyOwnership", "skipping for windows")
548
+ resolveHead()
549
+ } else {
550
+ getCacheStat(function(er, cs) {
551
+ if (er) {
552
+ log.error("Could not get cache stat")
553
+ return cb(er)
554
+ }
555
+ chownr(p, cs.uid, cs.gid, function(er) {
556
+ if (er) {
557
+ log.error("Failed to change folder ownership under npm cache for %s", p)
558
+ return cb(er)
559
+ }
560
+ resolveHead()
561
+ })
562
+ })
563
+ }
564
+ }
565
+
566
+ function resolveHead () {
567
+ exec(git, resolve, {cwd: p, env: env}, function (er, stdout, stderr) {
568
+ stdout = (stdout + "\n" + stderr).trim()
569
+ if (er) {
570
+ log.error("Failed resolving git HEAD (" + u + ")", stderr)
571
+ return cb(er)
572
+ }
573
+ log.verbose("git rev-list -n1 " + co, stdout)
574
+ var parsed = url.parse(origUrl)
575
+ parsed.hash = stdout
576
+ resolved = url.format(parsed)
577
+
578
+ // https://github.com/npm/npm/issues/3224
579
+ // node incorrectly sticks a / at the start of the path
580
+ // We know that the host won't change, so split and detect this
581
+ var spo = origUrl.split(parsed.host)
582
+ var spr = resolved.split(parsed.host)
583
+ if (spo[1].charAt(0) === ':' && spr[1].charAt(0) === '/')
584
+ spr[1] = spr[1].slice(1)
585
+ resolved = spr.join(parsed.host)
586
+
587
+ log.verbose('resolved git url', resolved)
588
+ next()
589
+ })
590
+ }
591
+
592
+ function next () {
593
+ mkdir(path.dirname(tmp), function (er) {
594
+ if (er) return cb(er)
595
+ var gzip = zlib.createGzip({ level: 9 })
596
+ var git = npm.config.get("git")
597
+ var args = ["archive", co, "--format=tar", "--prefix=package/"]
598
+ var out = fs.createWriteStream(tmp)
599
+ var env = gitEnv()
600
+ cb = once(cb)
601
+ var cp = spawn(git, args, { env: env, cwd: p })
602
+ cp.on("error", cb)
603
+ cp.stderr.on("data", function(chunk) {
604
+ log.silly(chunk.toString(), "git archive")
605
+ })
606
+
607
+ cp.stdout.pipe(gzip).pipe(out).on("close", function() {
608
+ addLocalTarball(tmp, function(er, data) {
609
+ if (data) data._resolved = resolved
610
+ cb(er, data)
611
+ })
612
+ })
613
+ })
614
+ }
615
+ }
616
+
617
+ var gitEnv_
618
+ function gitEnv () {
619
+ // git responds to env vars in some weird ways in post-receive hooks
620
+ // so don't carry those along.
621
+ if (gitEnv_) return gitEnv_
622
+ gitEnv_ = {}
623
+ for (var k in process.env) {
624
+ if (!~['GIT_PROXY_COMMAND','GIT_SSH','GIT_SSL_NO_VERIFY'].indexOf(k) && k.match(/^GIT/)) continue
625
+ gitEnv_[k] = process.env[k]
626
+ }
627
+ return gitEnv_
628
+ }
629
+
630
+
631
+ // only have one request in flight for a given
632
+ // name@blah thing.
633
+ var inFlightNames = {}
634
+ function addNamed (name, x, data, cb_) {
635
+ if (typeof cb_ !== "function") cb_ = data, data = null
636
+ log.verbose("addNamed", [name, x])
637
+
638
+ var k = name + "@" + x
639
+ if (!inFlightNames[k]) inFlightNames[k] = []
640
+ var iF = inFlightNames[k]
641
+ iF.push(cb_)
642
+ if (iF.length > 1) return
643
+
644
+ function cb (er, data) {
645
+ if (data && !data._fromGithub) data._from = k
646
+ unlock(k, function () {
647
+ var c
648
+ while (c = iF.shift()) c(er, data)
649
+ delete inFlightNames[k]
650
+ })
651
+ }
652
+
653
+ log.verbose("addNamed", [semver.valid(x), semver.validRange(x)])
654
+ lock(k, function (er, fd) {
655
+ if (er) return cb(er)
656
+
657
+ var fn = ( semver.valid(x, true) ? addNameVersion
658
+ : semver.validRange(x, true) ? addNameRange
659
+ : addNameTag
660
+ )
661
+ fn(name, x, data, cb)
662
+ })
663
+ }
664
+
665
+ function addNameTag (name, tag, data, cb_) {
666
+ if (typeof cb_ !== "function") cb_ = data, data = null
667
+ log.info("addNameTag", [name, tag])
668
+ var explicit = true
669
+ if (!tag) {
670
+ explicit = false
671
+ tag = npm.config.get("tag")
672
+ }
673
+
674
+ function cb(er, data) {
675
+ // might be username/project
676
+ // in that case, try it as a github url.
677
+ if (er && tag.split("/").length === 2) {
678
+ return maybeGithub(tag, name, er, cb_)
679
+ }
680
+ return cb_(er, data)
681
+ }
682
+
683
+ registry.get(name, function (er, data, json, response) {
684
+ if (er) return cb(er)
685
+ engineFilter(data)
686
+ if (data["dist-tags"] && data["dist-tags"][tag]
687
+ && data.versions[data["dist-tags"][tag]]) {
688
+ var ver = data["dist-tags"][tag]
689
+ return addNamed(name, ver, data.versions[ver], cb)
690
+ }
691
+ if (!explicit && Object.keys(data.versions).length) {
692
+ return addNamed(name, "*", data, cb)
693
+ }
694
+
695
+ er = installTargetsError(tag, data)
696
+ return cb(er)
697
+ })
698
+ }
699
+
700
+
701
+ function engineFilter (data) {
702
+ var npmv = npm.version
703
+ , nodev = npm.config.get("node-version")
704
+ , strict = npm.config.get("engine-strict")
705
+
706
+ if (!nodev || npm.config.get("force")) return data
707
+
708
+ Object.keys(data.versions || {}).forEach(function (v) {
709
+ var eng = data.versions[v].engines
710
+ if (!eng) return
711
+ if (!strict && !data.versions[v].engineStrict) return
712
+ if (eng.node && !semver.satisfies(nodev, eng.node, true)
713
+ || eng.npm && !semver.satisfies(npmv, eng.npm, true)) {
714
+ delete data.versions[v]
715
+ }
716
+ })
717
+ }
718
+
719
+ function addNameRange (name, range, data, cb) {
720
+ if (typeof cb !== "function") cb = data, data = null
721
+
722
+ range = semver.validRange(range, true)
723
+ if (range === null) return cb(new Error(
724
+ "Invalid version range: "+range))
725
+
726
+ log.silly("addNameRange", {name:name, range:range, hasData:!!data})
727
+
728
+ if (data) return next()
729
+ registry.get(name, function (er, d, json, response) {
730
+ if (er) return cb(er)
731
+ data = d
732
+ next()
733
+ })
734
+
735
+ function next () {
736
+ log.silly( "addNameRange", "number 2"
737
+ , {name:name, range:range, hasData:!!data})
738
+ engineFilter(data)
739
+
740
+ log.silly("addNameRange", "versions"
741
+ , [data.name, Object.keys(data.versions || {})])
742
+
743
+ // if the tagged version satisfies, then use that.
744
+ var tagged = data["dist-tags"][npm.config.get("tag")]
745
+ if (tagged
746
+ && data.versions[tagged]
747
+ && semver.satisfies(tagged, range, true)) {
748
+ return addNamed(name, tagged, data.versions[tagged], cb)
749
+ }
750
+
751
+ // find the max satisfying version.
752
+ var versions = Object.keys(data.versions || {})
753
+ var ms = semver.maxSatisfying(versions, range, true)
754
+ if (!ms) {
755
+ return cb(installTargetsError(range, data))
756
+ }
757
+
758
+ // if we don't have a registry connection, try to see if
759
+ // there's a cached copy that will be ok.
760
+ addNamed(name, ms, data.versions[ms], cb)
761
+ }
762
+ }
763
+
764
+ function installTargetsError (requested, data) {
765
+ var targets = Object.keys(data["dist-tags"]).filter(function (f) {
766
+ return (data.versions || {}).hasOwnProperty(f)
767
+ }).concat(Object.keys(data.versions || {}))
768
+
769
+ requested = data.name + (requested ? "@'" + requested + "'" : "")
770
+
771
+ targets = targets.length
772
+ ? "Valid install targets:\n" + JSON.stringify(targets) + "\n"
773
+ : "No valid targets found.\n"
774
+ + "Perhaps not compatible with your version of node?"
775
+
776
+ var er = new Error( "No compatible version found: "
777
+ + requested + "\n" + targets)
778
+ er.code = "ETARGET"
779
+ return er
780
+ }
781
+
782
+ function addNameVersion (name, v, data, cb) {
783
+ if (typeof cb !== "function") cb = data, data = null
784
+
785
+ var ver = semver.valid(v, true)
786
+ if (!ver) return cb(new Error("Invalid version: "+v))
787
+
788
+ var response
789
+
790
+ if (data) {
791
+ response = null
792
+ return next()
793
+ }
794
+ registry.get(name + "/" + ver, function (er, d, json, resp) {
795
+ if (er) return cb(er)
796
+ data = d
797
+ response = resp
798
+ next()
799
+ })
800
+
801
+ function next () {
802
+ deprCheck(data)
803
+ var dist = data.dist
804
+
805
+ if (!dist) return cb(new Error("No dist in "+data._id+" package"))
806
+
807
+ if (!dist.tarball) return cb(new Error(
808
+ "No dist.tarball in " + data._id + " package"))
809
+
810
+ if ((response && response.statusCode !== 304) || npm.config.get("force")) {
811
+ return fetchit()
812
+ }
813
+
814
+ // we got cached data, so let's see if we have a tarball.
815
+ var pkgroot = path.join(npm.cache, name, ver)
816
+ var pkgtgz = path.join(pkgroot, "package.tgz")
817
+ var pkgjson = path.join(pkgroot, "package", "package.json")
818
+ fs.stat(pkgtgz, function (er, s) {
819
+ if (!er) {
820
+ readJson(pkgjson, function (er, data) {
821
+ er = needName(er, data)
822
+ er = needVersion(er, data)
823
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR")
824
+ return cb(er)
825
+ if (er) return fetchit()
826
+ return cb(null, data)
827
+ })
828
+ } else return fetchit()
829
+ })
830
+
831
+ function fetchit () {
832
+ if (!npm.config.get("registry")) {
833
+ return cb(new Error("Cannot fetch: "+dist.tarball))
834
+ }
835
+
836
+ // use the same protocol as the registry.
837
+ // https registry --> https tarballs, but
838
+ // only if they're the same hostname, or else
839
+ // detached tarballs may not work.
840
+ var tb = url.parse(dist.tarball)
841
+ var rp = url.parse(npm.config.get("registry"))
842
+ if (tb.hostname === rp.hostname
843
+ && tb.protocol !== rp.protocol) {
844
+ tb.protocol = url.parse(npm.config.get("registry")).protocol
845
+ delete tb.href
846
+ }
847
+ tb = url.format(tb)
848
+
849
+ // only add non-shasum'ed packages if --forced.
850
+ // only ancient things would lack this for good reasons nowadays.
851
+ if (!dist.shasum && !npm.config.get("force")) {
852
+ return cb(new Error("package lacks shasum: " + data._id))
853
+ }
854
+ return addRemoteTarball( tb
855
+ , dist.shasum
856
+ , name+"-"+ver
857
+ , cb )
858
+ }
859
+ }
860
+ }
861
+
862
+ function addLocal (p, name, cb_) {
863
+ if (typeof cb_ !== "function") cb_ = name, name = ""
864
+
865
+ function cb (er, data) {
866
+ unlock(p, function () {
867
+ if (er) {
868
+ // if it doesn't have a / in it, it might be a
869
+ // remote thing.
870
+ if (p.indexOf("/") === -1 && p.charAt(0) !== "."
871
+ && (process.platform !== "win32" || p.indexOf("\\") === -1)) {
872
+ return addNamed(p, "", cb_)
873
+ }
874
+ log.error("addLocal", "Could not install %s", p)
875
+ return cb_(er)
876
+ }
877
+ if (data && !data._fromGithub) data._from = p
878
+ return cb_(er, data)
879
+ })
880
+ }
881
+
882
+ lock(p, function (er) {
883
+ if (er) return cb(er)
884
+ // figure out if this is a folder or file.
885
+ fs.stat(p, function (er, s) {
886
+ if (er) {
887
+ // might be username/project
888
+ // in that case, try it as a github url.
889
+ if (p.split("/").length === 2) {
890
+ return maybeGithub(p, name, er, cb)
891
+ }
892
+ return cb(er)
893
+ }
894
+ if (s.isDirectory()) addLocalDirectory(p, name, cb)
895
+ else addLocalTarball(p, name, cb)
896
+ })
897
+ })
898
+ }
899
+
900
+ function maybeGithub (p, name, er, cb) {
901
+ var u = "git://github.com/" + p
902
+ , up = url.parse(u)
903
+ log.info("maybeGithub", "Attempting %s from %s", p, u)
904
+
905
+ return addRemoteGit(u, up, name, true, function (er2, data) {
906
+ if (er2) {
907
+ var upriv = "git+ssh://git@github.com:" + p
908
+ , uppriv = url.parse(upriv)
909
+
910
+ log.info("maybeGithub", "Attempting %s from %s", p, upriv)
911
+
912
+ return addRemoteGit(upriv, uppriv, false, name, function (er3, data) {
913
+ if (er3) return cb(er)
914
+ success(upriv, data)
915
+ })
916
+ }
917
+ success(u, data)
918
+ })
919
+
920
+ function success (u, data) {
921
+ data._from = u
922
+ data._fromGithub = true
923
+ return cb(null, data)
924
+ }
925
+ }
926
+
927
+ function addLocalTarball (p, name, shasum, cb_) {
928
+ if (typeof cb_ !== "function") cb_ = shasum, shasum = null
929
+ if (typeof cb_ !== "function") cb_ = name, name = ""
930
+ // if it's a tar, and not in place,
931
+ // then unzip to .tmp, add the tmp folder, and clean up tmp
932
+ if (pathIsInside(p, npm.tmp))
933
+ return addTmpTarball(p, name, shasum, cb_)
934
+
935
+ if (pathIsInside(p, npm.cache)) {
936
+ if (path.basename(p) !== "package.tgz") return cb_(new Error(
937
+ "Not a valid cache tarball name: "+p))
938
+ return addPlacedTarball(p, name, shasum, cb_)
939
+ }
940
+
941
+ function cb (er, data) {
942
+ if (data) data._resolved = p
943
+ return cb_(er, data)
944
+ }
945
+
946
+ // just copy it over and then add the temp tarball file.
947
+ var tmp = path.join(npm.tmp, name + Date.now()
948
+ + "-" + Math.random(), "tmp.tgz")
949
+ mkdir(path.dirname(tmp), function (er) {
950
+ if (er) return cb(er)
951
+ var from = fs.createReadStream(p)
952
+ , to = fs.createWriteStream(tmp)
953
+ , errState = null
954
+ function errHandler (er) {
955
+ if (errState) return
956
+ return cb(errState = er)
957
+ }
958
+ from.on("error", errHandler)
959
+ to.on("error", errHandler)
960
+ to.on("close", function () {
961
+ if (errState) return
962
+ log.verbose("chmod", tmp, npm.modes.file.toString(8))
963
+ fs.chmod(tmp, npm.modes.file, function (er) {
964
+ if (er) return cb(er)
965
+ addTmpTarball(tmp, name, shasum, cb)
966
+ })
967
+ })
968
+ from.pipe(to)
969
+ })
970
+ }
971
+
972
+ // to maintain the cache dir's permissions consistently.
973
+ var cacheStat = null
974
+ function getCacheStat (cb) {
975
+ if (cacheStat) return cb(null, cacheStat)
976
+ fs.stat(npm.cache, function (er, st) {
977
+ if (er) return makeCacheDir(cb)
978
+ if (!st.isDirectory()) {
979
+ log.error("getCacheStat", "invalid cache dir %j", npm.cache)
980
+ return cb(er)
981
+ }
982
+ return cb(null, cacheStat = st)
983
+ })
984
+ }
985
+
986
+ function makeCacheDir (cb) {
987
+ if (!process.getuid) return mkdir(npm.cache, cb)
988
+
989
+ var uid = +process.getuid()
990
+ , gid = +process.getgid()
991
+
992
+ if (uid === 0) {
993
+ if (process.env.SUDO_UID) uid = +process.env.SUDO_UID
994
+ if (process.env.SUDO_GID) gid = +process.env.SUDO_GID
995
+ }
996
+ if (uid !== 0 || !process.env.HOME) {
997
+ cacheStat = {uid: uid, gid: gid}
998
+ return mkdir(npm.cache, afterMkdir)
999
+ }
1000
+
1001
+ fs.stat(process.env.HOME, function (er, st) {
1002
+ if (er) {
1003
+ log.error("makeCacheDir", "homeless?")
1004
+ return cb(er)
1005
+ }
1006
+ cacheStat = st
1007
+ log.silly("makeCacheDir", "cache dir uid, gid", [st.uid, st.gid])
1008
+ return mkdir(npm.cache, afterMkdir)
1009
+ })
1010
+
1011
+ function afterMkdir (er, made) {
1012
+ if (er || !cacheStat || isNaN(cacheStat.uid) || isNaN(cacheStat.gid)) {
1013
+ return cb(er, cacheStat)
1014
+ }
1015
+
1016
+ if (!made) return cb(er, cacheStat)
1017
+
1018
+ // ensure that the ownership is correct.
1019
+ chownr(made, cacheStat.uid, cacheStat.gid, function (er) {
1020
+ return cb(er, cacheStat)
1021
+ })
1022
+ }
1023
+ }
1024
+
1025
+
1026
+
1027
+
1028
+ function addPlacedTarball (p, name, shasum, cb) {
1029
+ if (!cb) cb = name, name = ""
1030
+ getCacheStat(function (er, cs) {
1031
+ if (er) return cb(er)
1032
+ return addPlacedTarball_(p, name, cs.uid, cs.gid, shasum, cb)
1033
+ })
1034
+ }
1035
+
1036
+ // Resolved sum is the shasum from the registry dist object, but
1037
+ // *not* necessarily the shasum of this tarball, because for stupid
1038
+ // historical reasons, npm re-packs each package an extra time through
1039
+ // a temp directory, so all installed packages are actually built with
1040
+ // *this* version of npm, on this machine.
1041
+ //
1042
+ // Once upon a time, this meant that we could change package formats
1043
+ // around and fix junk that might be added by incompatible tar
1044
+ // implementations. Then, for a while, it was a way to correct bs
1045
+ // added by bugs in our own tar implementation. Now, it's just
1046
+ // garbage, but cleaning it up is a pain, and likely to cause issues
1047
+ // if anything is overlooked, so it's not high priority.
1048
+ //
1049
+ // If you're bored, and looking to make npm go faster, and you've
1050
+ // already made it this far in this file, here's a better methodology:
1051
+ //
1052
+ // cache.add should really be cache.place. That is, it should take
1053
+ // a set of arguments like it does now, but then also a destination
1054
+ // folder.
1055
+ //
1056
+ // cache.add('foo@bar', '/path/node_modules/foo', cb)
1057
+ //
1058
+ // 1. Resolve 'foo@bar' to some specific:
1059
+ // - git url
1060
+ // - local folder
1061
+ // - local tarball
1062
+ // - tarball url
1063
+ // 2. If resolved through the registry, then pick up the dist.shasum
1064
+ // along the way.
1065
+ // 3. Acquire request() stream fetching bytes: FETCH
1066
+ // 4. FETCH.pipe(tar unpack stream to dest)
1067
+ // 5. FETCH.pipe(shasum generator)
1068
+ // When the tar and shasum streams both finish, make sure that the
1069
+ // shasum matches dist.shasum, and if not, clean up and bail.
1070
+ //
1071
+ // publish(cb)
1072
+ //
1073
+ // 1. read package.json
1074
+ // 2. get root package object (for rev, and versions)
1075
+ // 3. update root package doc with version info
1076
+ // 4. remove _attachments object
1077
+ // 5. remove versions object
1078
+ // 5. jsonify, remove last }
1079
+ // 6. get stream: registry.put(/package)
1080
+ // 7. write trailing-}-less JSON
1081
+ // 8. write "_attachments":
1082
+ // 9. JSON.stringify(attachments), remove trailing }
1083
+ // 10. Write start of attachments (stubs)
1084
+ // 11. JSON(filename)+':{"type":"application/octet-stream","data":"'
1085
+ // 12. acquire tar packing stream, PACK
1086
+ // 13. PACK.pipe(PUT)
1087
+ // 14. PACK.pipe(shasum generator)
1088
+ // 15. when PACK finishes, get shasum
1089
+ // 16. PUT.write('"}},') (finish _attachments
1090
+ // 17. update "versions" object with current package version
1091
+ // (including dist.shasum and dist.tarball)
1092
+ // 18. write '"versions":' + JSON(versions)
1093
+ // 19. write '}}' (versions, close main doc)
1094
+
1095
+ function addPlacedTarball_ (p, name, uid, gid, resolvedSum, cb) {
1096
+ // now we know it's in place already as .cache/name/ver/package.tgz
1097
+ // unpack to .cache/name/ver/package/, read the package.json,
1098
+ // and fire cb with the json data.
1099
+ var target = path.dirname(p)
1100
+ , folder = path.join(target, "package")
1101
+
1102
+ lock(folder, function (er) {
1103
+ if (er) return cb(er)
1104
+ rmUnpack()
1105
+ })
1106
+
1107
+ function rmUnpack () {
1108
+ rm(folder, function (er) {
1109
+ unlock(folder, function () {
1110
+ if (er) {
1111
+ log.error("addPlacedTarball", "Could not remove %j", folder)
1112
+ return cb(er)
1113
+ }
1114
+ thenUnpack()
1115
+ })
1116
+ })
1117
+ }
1118
+
1119
+ function thenUnpack () {
1120
+ tar.unpack(p, folder, null, null, uid, gid, function (er) {
1121
+ if (er) {
1122
+ log.error("addPlacedTarball", "Could not unpack %j to %j", p, target)
1123
+ return cb(er)
1124
+ }
1125
+ // calculate the sha of the file that we just unpacked.
1126
+ // this is so that the data is available when publishing.
1127
+ sha.get(p, function (er, shasum) {
1128
+ if (er) {
1129
+ log.error("addPlacedTarball", "shasum fail", p)
1130
+ return cb(er)
1131
+ }
1132
+ readJson(path.join(folder, "package.json"), function (er, data) {
1133
+ er = needName(er, data)
1134
+ er = needVersion(er, data)
1135
+ if (er) {
1136
+ log.error("addPlacedTarball", "Couldn't read json in %j"
1137
+ , folder)
1138
+ return cb(er)
1139
+ }
1140
+
1141
+ data.dist = data.dist || {}
1142
+ data.dist.shasum = shasum
1143
+ deprCheck(data)
1144
+ asyncMap([p], function (f, cb) {
1145
+ log.verbose("chmod", f, npm.modes.file.toString(8))
1146
+ fs.chmod(f, npm.modes.file, cb)
1147
+ }, function (f, cb) {
1148
+ if (process.platform === "win32") {
1149
+ log.silly("chown", "skipping for windows", f)
1150
+ cb()
1151
+ } else if (typeof uid === "number"
1152
+ && typeof gid === "number"
1153
+ && parseInt(uid, 10) === uid
1154
+ && parseInt(gid, 10) === gid) {
1155
+ log.verbose("chown", f, [uid, gid])
1156
+ fs.chown(f, uid, gid, cb)
1157
+ } else {
1158
+ log.verbose("chown", "skip for invalid uid/gid", [f, uid, gid])
1159
+ cb()
1160
+ }
1161
+ }, function (er) {
1162
+ cb(er, data)
1163
+ })
1164
+ })
1165
+ })
1166
+ })
1167
+ }
1168
+ }
1169
+
1170
+ // At this point, if shasum is set, it's something that we've already
1171
+ // read and checked. Just stashing it in the data at this point.
1172
+ function addLocalDirectory (p, name, shasum, cb) {
1173
+ if (typeof cb !== "function") cb = shasum, shasum = ""
1174
+ if (typeof cb !== "function") cb = name, name = ""
1175
+ // if it's a folder, then read the package.json,
1176
+ // tar it to the proper place, and add the cache tar
1177
+ if (pathIsInside(p, npm.cache)) return cb(new Error(
1178
+ "Adding a cache directory to the cache will make the world implode."))
1179
+ readJson(path.join(p, "package.json"), false, function (er, data) {
1180
+ er = needName(er, data)
1181
+ er = needVersion(er, data)
1182
+ if (er) return cb(er)
1183
+ deprCheck(data)
1184
+ var random = Date.now() + "-" + Math.random()
1185
+ , tmp = path.join(npm.tmp, random)
1186
+ , tmptgz = path.resolve(tmp, "tmp.tgz")
1187
+ , placed = path.resolve( npm.cache, data.name
1188
+ , data.version, "package.tgz" )
1189
+ , placeDirect = path.basename(p) === "package"
1190
+ , tgz = placeDirect ? placed : tmptgz
1191
+ getCacheStat(function (er, cs) {
1192
+ mkdir(path.dirname(tgz), function (er, made) {
1193
+ if (er) return cb(er)
1194
+
1195
+ var fancy = !pathIsInside(p, npm.tmp)
1196
+ && !pathIsInside(p, npm.cache)
1197
+ tar.pack(tgz, p, data, fancy, function (er) {
1198
+ if (er) {
1199
+ log.error( "addLocalDirectory", "Could not pack %j to %j"
1200
+ , p, tgz )
1201
+ return cb(er)
1202
+ }
1203
+
1204
+ // if we don't get a cache stat, or if the gid/uid is not
1205
+ // a number, then just move on. chown would fail anyway.
1206
+ if (!cs || isNaN(cs.uid) || isNaN(cs.gid)) return cb()
1207
+
1208
+ chownr(made || tgz, cs.uid, cs.gid, function (er) {
1209
+ if (er) return cb(er)
1210
+ addLocalTarball(tgz, name, shasum, cb)
1211
+ })
1212
+ })
1213
+ })
1214
+ })
1215
+ })
1216
+ }
1217
+
1218
+ function addTmpTarball (tgz, name, shasum, cb) {
1219
+ if (!cb) cb = name, name = ""
1220
+ getCacheStat(function (er, cs) {
1221
+ if (er) return cb(er)
1222
+ var contents = path.dirname(tgz)
1223
+ tar.unpack( tgz, path.resolve(contents, "package")
1224
+ , null, null
1225
+ , cs.uid, cs.gid
1226
+ , function (er) {
1227
+ if (er) {
1228
+ return cb(er)
1229
+ }
1230
+ addLocalDirectory(path.resolve(contents, "package"), name, shasum, cb)
1231
+ })
1232
+ })
1233
+ }
1234
+
1235
+ function unpack (pkg, ver, unpackTarget, dMode, fMode, uid, gid, cb) {
1236
+ if (typeof cb !== "function") cb = gid, gid = null
1237
+ if (typeof cb !== "function") cb = uid, uid = null
1238
+ if (typeof cb !== "function") cb = fMode, fMode = null
1239
+ if (typeof cb !== "function") cb = dMode, dMode = null
1240
+
1241
+ read(pkg, ver, false, function (er, data) {
1242
+ if (er) {
1243
+ log.error("unpack", "Could not read data for %s", pkg + "@" + ver)
1244
+ return cb(er)
1245
+ }
1246
+ npm.commands.unbuild([unpackTarget], true, function (er) {
1247
+ if (er) return cb(er)
1248
+ tar.unpack( path.join(npm.cache, pkg, ver, "package.tgz")
1249
+ , unpackTarget
1250
+ , dMode, fMode
1251
+ , uid, gid
1252
+ , cb )
1253
+ })
1254
+ })
1255
+ }
1256
+
1257
+ var deprecated = {}
1258
+ , deprWarned = {}
1259
+ function deprCheck (data) {
1260
+ if (deprecated[data._id]) data.deprecated = deprecated[data._id]
1261
+ if (data.deprecated) deprecated[data._id] = data.deprecated
1262
+ else return
1263
+ if (!deprWarned[data._id]) {
1264
+ deprWarned[data._id] = true
1265
+ log.warn("deprecated", "%s: %s", data._id, data.deprecated)
1266
+ }
1267
+ }
1268
+
1269
+ function lockFileName (u) {
1270
+ var c = u.replace(/[^a-zA-Z0-9]+/g, "-").replace(/^-+|-+$/g, "")
1271
+ , h = crypto.createHash("sha1").update(u).digest("hex")
1272
+ h = h.substr(0, 8)
1273
+ c = c.substr(-32)
1274
+ log.silly("lockFile", h + "-" + c, u)
1275
+ return path.resolve(npm.config.get("cache"), h + "-" + c + ".lock")
1276
+ }
1277
+
1278
+ var myLocks = {}
1279
+ function lock (u, cb) {
1280
+ // the cache dir needs to exist already for this.
1281
+ getCacheStat(function (er, cs) {
1282
+ if (er) return cb(er)
1283
+ var opts = { stale: npm.config.get("cache-lock-stale")
1284
+ , retries: npm.config.get("cache-lock-retries")
1285
+ , wait: npm.config.get("cache-lock-wait") }
1286
+ var lf = lockFileName(u)
1287
+ log.verbose("lock", u, lf)
1288
+ lockFile.lock(lf, opts, function(er) {
1289
+ if (!er) myLocks[lf] = true
1290
+ cb(er)
1291
+ })
1292
+ })
1293
+ }
1294
+
1295
+ function unlock (u, cb) {
1296
+ var lf = lockFileName(u)
1297
+ , locked = myLocks[lf]
1298
+ if (locked === false) {
1299
+ return process.nextTick(cb)
1300
+ } else if (locked === true) {
1301
+ myLocks[lf] = false
1302
+ lockFile.unlock(lockFileName(u), cb)
1303
+ } else {
1304
+ throw new Error("Attempt to unlock " + u + ", which hasn't been locked")
1305
+ }
1306
+ }
1307
+
1308
+ function needName(er, data) {
1309
+ return er ? er
1310
+ : (data && !data.name) ? new Error("No name provided")
1311
+ : null
1312
+ }
1313
+
1314
+ function needVersion(er, data) {
1315
+ return er ? er
1316
+ : (data && !data.version) ? new Error("No version provided")
1317
+ : null
1318
+ }