gina 0.1.6-alpha.14 → 0.1.6-alpha.140

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (390) hide show
  1. package/LICENSE +1 -1
  2. package/README-4Contributors.md +14 -8
  3. package/README.md +13 -4
  4. package/bin/cli +16 -2
  5. package/bin/gina +29 -1
  6. package/framework/{v0.1.6-alpha.14/lib/inherits → v0.1.6-alpha.140}/LICENSE +1 -1
  7. package/framework/v0.1.6-alpha.140/VERSION +1 -0
  8. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/plugin/README.md +1 -0
  9. package/framework/v0.1.6-alpha.140/core/asset/plugin/dist/vendor/gina/css/gina.min.css.map +1 -0
  10. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/plugin/dist/vendor/gina/html/toolbar.html +1 -1
  11. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/plugin/dist/vendor/gina/js/gina.js +765 -256
  12. package/framework/v0.1.6-alpha.140/core/asset/plugin/dist/vendor/gina/js/gina.min.js +782 -0
  13. package/framework/v0.1.6-alpha.140/core/asset/plugin/dist/vendor/gina/js/gina.min.js.map +8 -0
  14. package/framework/v0.1.6-alpha.140/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js +8 -0
  15. package/framework/v0.1.6-alpha.140/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.map +8 -0
  16. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/config.js +158 -78
  17. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/index.js +108 -26
  18. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/connector.v4.js +124 -22
  19. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/session-store.v4.js +5 -2
  20. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/controller/controller.js +762 -189
  21. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/controller/index.js +2 -2
  22. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/.github/workflows/ci.yml +24 -0
  23. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/.github/workflows/lint.yml +23 -0
  24. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/README.md +191 -0
  25. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-multipart-fields-100mb-big.js +149 -0
  26. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-multipart-fields-100mb-small.js +143 -0
  27. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-multipart-files-100mb-big.js +154 -0
  28. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-multipart-files-100mb-small.js +148 -0
  29. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-urlencoded-fields-100pairs-small.js +101 -0
  30. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/bench/bench-urlencoded-fields-900pairs-small-alt.js +84 -0
  31. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/lib/index.js +57 -0
  32. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/lib/types/multipart.js +680 -0
  33. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/lib/types/urlencoded.js +350 -0
  34. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/lib/utils.js +596 -0
  35. package/framework/v0.1.6-alpha.140/core/deps/busboy-1.6.0/package.json +22 -0
  36. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/.travis.yml +4 -0
  37. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/LICENSE +21 -0
  38. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/bool.js +10 -0
  39. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/boolean_double.js +7 -0
  40. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/boolean_single.js +7 -0
  41. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/default_hash.js +8 -0
  42. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/default_singles.js +7 -0
  43. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/divide.js +8 -0
  44. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/line_count.js +20 -0
  45. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/line_count_options.js +29 -0
  46. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/line_count_wrap.js +29 -0
  47. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/nonopt.js +4 -0
  48. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/reflect.js +2 -0
  49. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/short.js +3 -0
  50. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/string.js +11 -0
  51. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/usage-options.js +19 -0
  52. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/example/xup.js +10 -0
  53. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/index.js +343 -0
  54. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/package.json +31 -0
  55. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/package.json.dist +39 -0
  56. package/framework/v0.1.6-alpha.140/core/deps/optimist-0.6.1/readme.markdown +513 -0
  57. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/HISTORY.md +498 -0
  58. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/LICENSE +7 -0
  59. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/README.md +88 -0
  60. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/bin/swig.js +161 -0
  61. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/bin/swig.js.dist +161 -0
  62. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/dist/swig.min.js +7 -0
  63. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/dist/swig.min.js.map +8 -0
  64. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/index.js +1 -0
  65. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/dateformatter.js +198 -0
  66. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/filters.js +630 -0
  67. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/lexer.js +306 -0
  68. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/loaders/filesystem.js +59 -0
  69. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/loaders/index.js +53 -0
  70. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/loaders/memory.js +63 -0
  71. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/parser.js +744 -0
  72. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/swig.js +740 -0
  73. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/autoescape.js +37 -0
  74. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/block.js +25 -0
  75. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/else.js +25 -0
  76. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/elseif.js +28 -0
  77. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/extends.js +19 -0
  78. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/filter.js +68 -0
  79. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/for.js +130 -0
  80. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/if.js +86 -0
  81. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/import.js +91 -0
  82. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/include.js +100 -0
  83. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/index.js +16 -0
  84. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/macro.js +79 -0
  85. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/parent.js +51 -0
  86. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/raw.js +23 -0
  87. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/set.js +109 -0
  88. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/tags/spaceless.js +42 -0
  89. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/lib/utils.js +184 -0
  90. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/package.json +57 -0
  91. package/framework/v0.1.6-alpha.140/core/deps/swig-1.4.2/package.json.dist +61 -0
  92. package/framework/v0.1.6-alpha.140/core/deps/swig-client/swig.js +5031 -0
  93. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/dev/index.js +1 -1
  94. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/dev/lib/factory.js +1 -1
  95. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/gna.js +104 -22
  96. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/index.js +3 -3
  97. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/src/make.js +1 -1
  98. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/mime.types +1 -0
  99. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/model/entity.js +5 -5
  100. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/model/index.js +30 -26
  101. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/model/template/entityFactory.js +1 -1
  102. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/model/template/index.js +1 -1
  103. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/index.js +3 -3
  104. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/file/package.json +2 -2
  105. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/intl/package.json +2 -2
  106. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/storage/package.json +2 -2
  107. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/validator/package.json +2 -2
  108. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/validator/src/form-validator.js +39 -27
  109. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/validator/src/main.js +477 -114
  110. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/router.js +92 -47
  111. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/server.isaac.js +94 -43
  112. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/server.js +329 -134
  113. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/status.codes +1 -11
  114. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/controllers/setup.js +2 -2
  115. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/command/gina.tpl +1 -1
  116. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/env.json +19 -0
  117. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/templates.json +4 -2
  118. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/console.js +1 -1
  119. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/context.js +30 -13
  120. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/data/package.json +2 -2
  121. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/data/src/main.js +1 -1
  122. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/dateFormat.js +1 -1
  123. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/index.js +1 -1
  124. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/json/package.json +2 -2
  125. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/json/src/main.js +6 -4
  126. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/path.js +31 -15
  127. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/plugins/package.json +2 -2
  128. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/plugins/src/api-error.js +2 -2
  129. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/plugins/src/main.js +1 -1
  130. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/task.js +2 -2
  131. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/text.js +1 -1
  132. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/archiver/package.json +2 -2
  133. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/archiver/src/main.js +11 -11
  134. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/add.js +2 -1
  135. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/start.js +21 -8
  136. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/get.js +1 -1
  137. package/framework/v0.1.6-alpha.140/lib/cmd/env/help.js +30 -0
  138. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/build.js +1 -1
  139. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/dot.js +21 -0
  140. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/init.js +19 -1
  141. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/link-node-modules.js +2 -3
  142. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/link.js +3 -2
  143. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/restart.js +3 -3
  144. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/start.js +1 -1
  145. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/tail.js +29 -12
  146. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/version.js +15 -1
  147. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/helper.js +8 -4
  148. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/index.js +1 -1
  149. package/framework/v0.1.6-alpha.140/lib/cmd/minion/help.txt +18 -0
  150. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/reset.js +1 -1
  151. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/add.js +7 -2
  152. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/arguments.json +1 -0
  153. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/build.js +4 -4
  154. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/help.txt +4 -0
  155. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/list.js +1 -1
  156. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/protocol/list.js +71 -50
  157. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/collection/package.json +2 -2
  158. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/collection/src/main.js +20 -14
  159. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/config.js +1 -1
  160. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cron/package.json +2 -2
  161. package/framework/v0.1.6-alpha.140/lib/domain/dist/2025-03-14_13-41-20_UTC.dat +15754 -0
  162. package/framework/v0.1.6-alpha.140/lib/domain/dist/public_suffix_list.dat +15754 -0
  163. package/framework/v0.1.6-alpha.140/lib/domain/exemples/backend.js +12 -0
  164. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/domain/package.json +2 -2
  165. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/domain/src/main.js +20 -6
  166. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/generator/index.js +1 -1
  167. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/index.js +1 -1
  168. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140/lib/inherits}/LICENSE +1 -1
  169. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/package.json +2 -2
  170. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/src/main.js +1 -1
  171. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/package.json +2 -2
  172. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/mq/listener.js +10 -2
  173. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/helper.js +1 -1
  174. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/main.js +1 -1
  175. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/math/index.js +1 -1
  176. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/package.json +2 -2
  177. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/model.js +3 -3
  178. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/proc.js +10 -2
  179. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/routing/package.json +2 -2
  180. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/routing/src/main.js +82 -26
  181. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/session-store.js +3 -3
  182. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/swig-filters/package.json +2 -2
  183. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/swig-filters/src/main.js +76 -15
  184. package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/validator.js +2 -2
  185. package/framework/v0.1.6-alpha.140/package.json +11 -0
  186. package/package.json +3 -3
  187. package/resources/package.json.template +1 -1
  188. package/script/post_install.js +4 -4
  189. package/script/pre_install.js +3 -3
  190. package/utils/helper.js +38 -14
  191. package/framework/v0.1.6-alpha.14/VERSION +0 -1
  192. package/framework/v0.1.6-alpha.14/core/asset/plugin/dist/vendor/gina/css/gina.min.css.map +0 -1
  193. package/framework/v0.1.6-alpha.14/core/asset/plugin/dist/vendor/gina/js/gina.min.js +0 -766
  194. package/framework/v0.1.6-alpha.14/core/asset/plugin/dist/vendor/gina/js/gina.min.js.map +0 -8
  195. package/framework/v0.1.6-alpha.14/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js +0 -7
  196. package/framework/v0.1.6-alpha.14/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.map +0 -8
  197. package/framework/v0.1.6-alpha.14/core/deps/busboy/.travis.yml +0 -17
  198. package/framework/v0.1.6-alpha.14/core/deps/busboy/README.md +0 -225
  199. package/framework/v0.1.6-alpha.14/core/deps/busboy/deps/encoding/encoding-indexes.js +0 -73
  200. package/framework/v0.1.6-alpha.14/core/deps/busboy/deps/encoding/encoding.js +0 -2391
  201. package/framework/v0.1.6-alpha.14/core/deps/busboy/lib/main.js +0 -89
  202. package/framework/v0.1.6-alpha.14/core/deps/busboy/lib/types/multipart.js +0 -328
  203. package/framework/v0.1.6-alpha.14/core/deps/busboy/lib/types/urlencoded.js +0 -214
  204. package/framework/v0.1.6-alpha.14/core/deps/busboy/lib/utils.js +0 -191
  205. package/framework/v0.1.6-alpha.14/core/deps/busboy/package.json +0 -69
  206. package/framework/v0.1.6-alpha.14/lib/domain/dist/public_suffix_list.dat +0 -14186
  207. package/framework/v0.1.6-alpha.14/lib/domain/exemples/backend.js +0 -0
  208. package/framework/v0.1.6-alpha.14/package.json +0 -14
  209. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/AUTHORS +0 -0
  210. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/html/nolayout.html +0 -0
  211. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/html/static.html +0 -0
  212. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/android-chrome-192x192.png +0 -0
  213. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/android-chrome-512x512.png +0 -0
  214. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/apple-touch-icon.png +0 -0
  215. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/favicon-16x16.png +0 -0
  216. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/favicon-32x32.png +0 -0
  217. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/img/favicon.ico +0 -0
  218. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/plugin/dist/vendor/gina/css/gina.min.css +0 -0
  219. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/asset/plugin/uuid.json +0 -0
  220. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/connector.js +0 -0
  221. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/connector.v2.js +0 -0
  222. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/connector.v3.js +0 -0
  223. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/n1ql.js +0 -0
  224. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/session-store.js +0 -0
  225. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/session-store.v2.js +0 -0
  226. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/connectors/couchbase/lib/session-store.v3.js +0 -0
  227. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/controller/controller.framework.js +0 -0
  228. /package/framework/{v0.1.6-alpha.14/core/deps/busboy → v0.1.6-alpha.140/core/deps/busboy-1.6.0}/LICENSE +0 -0
  229. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/deps/swig-client/swig-2.0.0.min.js +0 -0
  230. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/dev/lib/class.js +0 -0
  231. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/dev/lib/tools.js +0 -0
  232. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/README.md +0 -0
  233. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/currency.json +0 -0
  234. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/dist/language/en.json +0 -0
  235. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/dist/language/fr.json +0 -0
  236. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/dist/region/en.json +0 -0
  237. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/dist/region/fr.json +0 -0
  238. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/src/resources/currency.csv +0 -0
  239. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/src/resources/region.csv +0 -0
  240. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/locales/src/resources/region.mapping.json +0 -0
  241. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/README.md +0 -0
  242. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/file/README.md +0 -0
  243. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/file/build.json +0 -0
  244. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/intl/README.md +0 -0
  245. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/intl/build.json +0 -0
  246. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/intl/src/main.js +0 -0
  247. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/storage/README.md +0 -0
  248. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/storage/build.json +0 -0
  249. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/storage/src/main.js +0 -0
  250. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/validator/README.md +0 -0
  251. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/plugins/lib/validator/build.json +0 -0
  252. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/server.express.js +0 -0
  253. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/_gitignore +0 -0
  254. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/config/app.json +0 -0
  255. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/config/routing.json +0 -0
  256. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/config/settings.json +0 -0
  257. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/config/settings.server.json +0 -0
  258. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/config/templates.json +0 -0
  259. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/controllers/controller.content.js +0 -0
  260. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/controllers/controller.js +0 -0
  261. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle/index.js +0 -0
  262. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_namespace/controllers/controller.js +0 -0
  263. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_public/css/default.css +0 -0
  264. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_public/css/vendor/readme.md +0 -0
  265. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_public/favicon.ico +0 -0
  266. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_public/js/vendor/readme.md +0 -0
  267. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_public/readme.md +0 -0
  268. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_templates/handlers/main.js +0 -0
  269. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_templates/html/content/homepage.html +0 -0
  270. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_templates/html/includes/error-msg-noscript.html +0 -0
  271. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_templates/html/includes/error-msg-outdated-browser.html +0 -0
  272. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/boilerplate/bundle_templates/html/layouts/main.html +0 -0
  273. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/command/gina.bat.tpl +0 -0
  274. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/manifest.json +0 -0
  275. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/package.json +0 -0
  276. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/settings.json +0 -0
  277. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/conf/statics.json +0 -0
  278. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/client/json/401.json +0 -0
  279. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/client/json/403.json +0 -0
  280. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/client/json/404.json +0 -0
  281. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/server/html/50x.html +0 -0
  282. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/server/json/500.json +0 -0
  283. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/error/server/json/503.json +0 -0
  284. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/core/template/extensions/logger/config.json +0 -0
  285. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/data/LICENSE +0 -0
  286. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/data/README.md +0 -0
  287. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/json/LICENSE +0 -0
  288. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/json/README.md +0 -0
  289. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/plugins/README.md +0 -0
  290. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/helpers/prototypes.js +0 -0
  291. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/archiver/README.md +0 -0
  292. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/archiver/build.json +0 -0
  293. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/archiver/src/dep/jszip.min.js +0 -0
  294. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/aliases.json +0 -0
  295. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/arguments.json +0 -0
  296. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/copy.js +0 -0
  297. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/cp.js +0 -0
  298. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/help.js +0 -0
  299. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/help.txt +0 -0
  300. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/list.js +0 -0
  301. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/remove.js +0 -0
  302. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/rename.js +0 -0
  303. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/restart.js +0 -0
  304. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/rm.js +0 -0
  305. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/status.js +0 -0
  306. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/bundle/stop.js +0 -0
  307. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/add.js +0 -0
  308. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/help.txt +0 -0
  309. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/link-dev.js +0 -0
  310. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/list.js +0 -0
  311. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/remove.js +0 -0
  312. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/rm.js +0 -0
  313. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/set.js +0 -0
  314. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/unset.js +0 -0
  315. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/env/use.js +0 -0
  316. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/get.js +0 -0
  317. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/help.js +0 -0
  318. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/help.txt +0 -0
  319. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/msg.json +0 -0
  320. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/open.js +0 -0
  321. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/set.js +0 -0
  322. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/status.js +0 -0
  323. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/stop.js +0 -0
  324. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/framework/update.js +0 -0
  325. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/gina-dev.1.md +0 -0
  326. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/gina-framework.1.md +0 -0
  327. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/gina.1.md +0 -0
  328. /package/framework/{v0.1.6-alpha.14/lib/cmd/env → v0.1.6-alpha.140/lib/cmd/minion}/help.js +0 -0
  329. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/msg.json +0 -0
  330. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/help.js +0 -0
  331. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/help.txt +0 -0
  332. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/inc/scan.js +0 -0
  333. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/list.js +0 -0
  334. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/port/set.js +0 -0
  335. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/help.js +0 -0
  336. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/import.js +0 -0
  337. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/move.js +0 -0
  338. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/remove.js +0 -0
  339. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/rename.js +0 -0
  340. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/restart.js +0 -0
  341. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/rm.js +0 -0
  342. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/start.js +0 -0
  343. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/status.js +0 -0
  344. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/project/stop.js +0 -0
  345. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/protocol/help.js +0 -0
  346. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/protocol/help.txt +0 -0
  347. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/protocol/set.js +0 -0
  348. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/add.js +0 -0
  349. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/help.js +0 -0
  350. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/help.txt +0 -0
  351. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/link-local.js +0 -0
  352. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/link-production.js +0 -0
  353. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/list.js +0 -0
  354. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/remove.js +0 -0
  355. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/rm.js +0 -0
  356. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/scope/use.js +0 -0
  357. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cmd/view/add.js +0 -0
  358. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/collection/README.md +0 -0
  359. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/collection/build.json +0 -0
  360. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cron/README.md +0 -0
  361. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/cron/src/main.js +0 -0
  362. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/domain/LICENSE +0 -0
  363. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/domain/README.md +0 -0
  364. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/domain/exemples/frontend.html +0 -0
  365. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/README.md +0 -0
  366. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/example/inheriting_eventemitter.js +0 -0
  367. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/example/protected_inheritance.js +0 -0
  368. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/example/simple_inheritance.js +0 -0
  369. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/inherits/example/super_attribute_overridden_by_child_on_init.js +0 -0
  370. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/README.md +0 -0
  371. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/default/index.js +0 -0
  372. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/file/index.js +0 -0
  373. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/file/lib/logrotator/README.md +0 -0
  374. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/file/lib/logrotator/index.js +0 -0
  375. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/mq/index.js +0 -0
  376. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/logger/src/containers/mq/speaker.js +0 -0
  377. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/README.md +0 -0
  378. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/example/merge.js +0 -0
  379. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/example/merge_2_literal objects.js +0 -0
  380. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/example/merge_and_preserve_first.js +0 -0
  381. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/merge/src/main.js +0 -0
  382. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/routing/README.md +0 -0
  383. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/routing/build.json +0 -0
  384. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/shell.js +0 -0
  385. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/swig-filters/README.md +0 -0
  386. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/url/README.md +0 -0
  387. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/url/index.js +0 -0
  388. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/url/mocks.json +0 -0
  389. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/url/routing.json +0 -0
  390. /package/framework/{v0.1.6-alpha.14 → v0.1.6-alpha.140}/lib/url/test.js +0 -0
@@ -4,14 +4,15 @@ const fs = require('fs');
4
4
  const os = require('os');
5
5
  const path = require('path');
6
6
  const EventEmitter = require('events').EventEmitter;
7
- const Busboy = require('./deps/busboy');
7
+ const swig = require('./deps/swig-1.4.2');
8
+ const Busboy = require('./deps/busboy-1.6.0');
8
9
  const Stream = require('stream');
9
10
  const zlib = require('zlib'); // gzip / deflate
10
11
  const util = require('util');
11
12
  var https = require('https');
12
13
  const sslChecker = require('ssl-checker');
13
14
 
14
- const swig = require( _(GINA_FRAMEWORK_DIR +'/node_modules/swig', true) );
15
+
15
16
  var Config = require('./config');
16
17
  var Router = require('./router');
17
18
  var lib = require('./../lib');
@@ -21,6 +22,8 @@ var merge = lib.merge;
21
22
  var Proc = lib.Proc;
22
23
  var console = lib.logger;
23
24
  var SwigFilters = lib.SwigFilters;
25
+ var Domain = lib.Domain;
26
+ var domainLib = new Domain();
24
27
 
25
28
  function Server(options) {
26
29
 
@@ -48,7 +51,7 @@ function Server(options) {
48
51
  var swigOptions = {
49
52
  autoescape: ( typeof(conf.autoescape) != 'undefined') ? conf.autoescape: false,
50
53
  loader: swig.loaders.fs(dir),
51
- cache: (conf.cacheless) ? false : 'memory'
54
+ cache: (conf.isCacheless) ? false : 'memory'
52
55
  };
53
56
 
54
57
  swig.setDefaults(swigOptions);
@@ -225,7 +228,13 @@ function Server(options) {
225
228
  init(options);
226
229
  }
227
230
 
228
-
231
+ /**
232
+ * Verify certificate validity
233
+ *
234
+ * @param {string} endpoint
235
+ * @param {number} port
236
+ * @returns
237
+ */
229
238
  this.verifyCertificate = async function(endpoint, port) {
230
239
  let sslDetails = null;
231
240
  console.debug('Checking certificate validity...');
@@ -293,6 +302,24 @@ function Server(options) {
293
302
 
294
303
  if (failed) {
295
304
  if (sslDetails.daysRemaining > -1) {
305
+ var isProxyHost = getContext('isProxyHost');
306
+ if ( /^true$/i.test(isProxyHost) ) {
307
+ console.warn("Host is behind a reverse proxy, skipping server.verifyCertificate(...) ");
308
+ return;
309
+ }
310
+ var rootDomain = domainLib.getRootDomain(endpoint).value;
311
+ hasMatchedEntry = false;
312
+ for (let i in sslDetails.validFor) {
313
+ if ( new RegExp(sslDetails.validFor[i].replace(/^\*\./, '') + '$').test(rootDomain) ) {
314
+ hasMatchedEntry = true;
315
+ break;
316
+ }
317
+ }
318
+ if (!hasMatchedEntry) {
319
+ console.warn(`[Certificate] "${endpoint}" : Root domain not matching your certificate. If you plan to run your service behind a revese proxy, please do not forget to add "proxy.json" at the root of your project while going to production.${'\n'} ${humanView}`);
320
+ return;
321
+ }
322
+ // sslDetails.validFor
296
323
  console.emerg(`[Certificate] ${endpoint} : It is like there is a problem with your CA certificate${'\n'} ${humanView}`);
297
324
  return;
298
325
  }
@@ -331,7 +358,7 @@ function Server(options) {
331
358
  , serverCoreConf = self.conf.core
332
359
  , routing = {}
333
360
  , reverseRouting = {}
334
- , cacheless = config.isCacheless()
361
+ , isCacheless = config.isCacheless()
335
362
  , env = self.env
336
363
  , scope = self.scope
337
364
  , apps = conf.allBundles // conf.bundles
@@ -371,7 +398,7 @@ function Server(options) {
371
398
  filename = main
372
399
  }
373
400
 
374
- if (cacheless) {
401
+ if (isCacheless) {
375
402
  delete require.cache[require.resolve(_(filename, true))]
376
403
  }
377
404
 
@@ -424,15 +451,15 @@ function Server(options) {
424
451
  }
425
452
 
426
453
  if (typeof(tmp[rule].url) != 'object') {
427
- if (tmp[rule].url.length > 1 && tmp[rule].url.substr(0,1) != '/') {
454
+ if (tmp[rule].url.length > 1 && tmp[rule].url.substring(0,1) != '/') {
428
455
  tmp[rule].url = '/'+tmp[rule].url
429
456
  }
430
- /** else if (tmp[rule].url.length > 1 && conf.envConf[apps[i]][env].server.webroot.substr(conf.envConf[apps[i]][env].server.webroot.length-1,1) == '/') {
431
- tmp[rule].url = tmp[rule].url.substr(1)
457
+ /** else if (tmp[rule].url.length > 1 && conf.envConf[apps[i]][env].server.webroot.substring(conf.envConf[apps[i]][env].server.webroot.length-1,1) == '/') {
458
+ tmp[rule].url = tmp[rule].url.substring(1)
432
459
  }*/
433
460
  else {
434
- if (wroot.substr(wroot.length-1,1) == '/') {
435
- wroot = wroot.substr(wroot.length-1,1).replace('/', '')
461
+ if (wroot.substring(wroot.length-1,1) == '/') {
462
+ wroot = wroot.substring(wroot.length-1,1).replace('/', '')
436
463
  }
437
464
  }
438
465
 
@@ -448,8 +475,8 @@ function Server(options) {
448
475
  localWroot = '/'+ routing[rule].bundle;
449
476
  conf.envConf[tmp[rule].bundle][env].server.webroot = localWroot
450
477
  }
451
- if (localWroot.substr(localWroot.length-1,1) == '/') {
452
- localWroot = localWroot.substr(localWroot.length-1,1).replace('/', '')
478
+ if (localWroot.substring(localWroot.length-1,1) == '/') {
479
+ localWroot = localWroot.substring(localWroot.length-1,1).replace('/', '')
453
480
  }
454
481
  if ( typeof(tmp[rule].param.ignoreWebRoot) == 'undefined' || !tmp[rule].param.ignoreWebRoot )
455
482
  tmp[rule].url = localWroot + tmp[rule].url
@@ -463,11 +490,11 @@ function Server(options) {
463
490
  } else {
464
491
 
465
492
  for (var u=0; u<tmp[rule].url.length; ++u) {
466
- if (tmp[rule].url[u].length > 1 && tmp[rule].url[u].substr(0,1) != '/') {
493
+ if (tmp[rule].url[u].length > 1 && tmp[rule].url[u].substring(0,1) != '/') {
467
494
  tmp[rule].url[u] = '/'+tmp[rule].url[u]
468
495
  } else {
469
- if (wroot.substr(wroot.length-1,1) == '/') {
470
- wroot = wroot.substr(wroot.length-1,1).replace('/', '')
496
+ if (wroot.substring(wroot.length-1,1) == '/') {
497
+ wroot = wroot.substring(wroot.length-1,1).replace('/', '')
471
498
  }
472
499
  }
473
500
  if ( typeof(tmp[rule].param.ignoreWebRoot) == 'undefined' || !tmp[rule].param.ignoreWebRoot )
@@ -584,7 +611,7 @@ function Server(options) {
584
611
  ) {
585
612
 
586
613
  // by default
587
- path = url.replace(url.substr(url.lastIndexOf('/')+1), '');
614
+ path = url.replace(url.substring(url.lastIndexOf('/')+1), '');
588
615
  if ( typeof(altConf) != 'undefined' && altConf ) {
589
616
  bundleConf = self.conf[altConf.split(/\@/)[1]][bundleConf.env];
590
617
  backedupPath = path;
@@ -592,7 +619,7 @@ function Server(options) {
592
619
  }
593
620
 
594
621
 
595
- // catch `statics.json` defined paths || bundleConf.staticResources.indexOf(url.replace(url.substr(url.lastIndexOf('/')+1), '')) > -1
622
+ // catch `statics.json` defined paths || bundleConf.staticResources.indexOf(url.replace(url.substring(url.lastIndexOf('/')+1), '')) > -1
596
623
  if ( bundleConf.staticResources.indexOf(path) > -1 || bundleConf.staticResources.indexOf(staticProps.firstLevel) > -1 ) {
597
624
  if ( typeof(altConf) != 'undefined' && altConf && backedupPath ) {
598
625
  filename = (bundleConf.staticResources.indexOf(path) > -1) ? bundleConf.content.statics[path] + url.replace(backedupPath, '/') : bundleConf.content.statics[staticProps.firstLevel] + url.replace(staticProps.firstLevel, '/');
@@ -631,8 +658,8 @@ function Server(options) {
631
658
  */
632
659
  var getAssets = function (bundleConf, layoutStr, swig, data) {
633
660
 
634
- // layout search for <link|script|img>
635
- var layoutAssets = layoutStr.match(/<link .*?<\/link>|<link .*?(rel\=\"(stylesheet|icon|manifest|(.*)\-icon))(.*)|<script.*?<\/script>|<img .*?(.*)/g) || [];
661
+ // layout search for <link|source|script|img>
662
+ var layoutAssets = layoutStr.match(/<link .*?<\/link>|<link .*?(rel\=\"(stylesheet|icon|manifest|(.*)\-icon))(.*)|<source .*?(type\=\"(image))(.*)|<script.*?<\/script>|<img .*?(.*)/g) || [];
636
663
 
637
664
  var assets = {}
638
665
  , cssFiles = []
@@ -652,63 +679,150 @@ function Server(options) {
652
679
  // layout assets
653
680
  i = 0;
654
681
  len = layoutAssets.length;
655
- var type = null
656
- , isAvailable = null
657
- , tag = null
658
- , properties = null
659
- , p = 0
660
- , pArr = []
682
+ var type = null
683
+ , isAvailable = null
684
+ , tag = null
685
+ , properties = null
686
+ , p = 0
687
+ , pArr = []
688
+ , sourceTagSrcSetStr = ''
661
689
  ;
662
690
  for (; i < len; ++i) {
663
691
 
664
692
  if (
665
- !/(\<img|\<link|\<script)/g.test(layoutAssets[i])
666
- || /\<img/.test(layoutAssets[i]) && /srcset/.test(layoutAssets[i]) // not able to handle this case for now
693
+ !/(\<img|\<link|\<source|\<script)/g.test(layoutAssets[i])
694
+ // ||
695
+ // not able to handle srcset case for now
696
+ /**
697
+ /\<img/.test(layoutAssets[i])
698
+ && /srcset/.test(layoutAssets[i])*/
667
699
  ) {
668
700
  continue;
669
701
  }
670
702
 
703
+ // https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel/preload
704
+ let asType = null;
705
+
671
706
  if ( /\<img/.test(layoutAssets[i]) ) {
672
707
  type = 'image';
673
708
  tag = 'img';
709
+ asType = type;
674
710
  }
675
711
 
676
- if ( /\<script/.test(layoutAssets[i]) ) {
677
- type = 'javascript';
678
- tag = 'script';
679
- }
712
+
680
713
 
681
714
  if ( /\<link/.test(layoutAssets[i]) ) {
682
- if ( /rel\=\"stylesheet/.test(layoutAssets[i]) ) {
683
- type = 'stylesheet';
684
- } else if ( /rel\=\"(icon|(.*)\-icon)/.test(layoutAssets[i]) ) {
685
- type = 'image';
686
- } else {
687
- type = 'file';
715
+ // if ( /rel\=\"stylesheet/.test(layoutAssets[i]) ) {
716
+ // type = 'stylesheet';
717
+ // } else if ( /rel\=\"(icon|(.*)\-icon)/.test(layoutAssets[i]) ) {
718
+ // type = 'image';
719
+ // } else {
720
+ // type = 'file';
721
+ // }
722
+ type = layoutAssets[i].match(/rel=\"[-a-z 0-9]+\"/)[0] || null;
723
+ if (type) {
724
+ type = type.replace(/^rel\=\"|"$/g, '');
725
+ }
726
+
727
+
728
+ switch (type) {
729
+ case /stylesheet/.test(type):
730
+ asType = 'style';
731
+ break;
732
+
733
+ case /javascript/.test(type):
734
+ asType = 'script';
735
+ break;
736
+
737
+ default:
738
+ asType = null;
739
+ if ( /icon/.test(type) ) {
740
+ asType = 'image';
741
+ // ignoring all (fav)icons type: rel="*icon*" case
742
+ continue;
743
+ }
744
+ if ( /font/.test(type) ) {
745
+ asType = 'font';
746
+ }
747
+ // if ( /manifest/.test(type) ) {
748
+ // asType = 'webmanifest';
749
+ // }
750
+ break;
688
751
  }
689
752
 
690
753
  tag = 'link';
691
754
  }
692
755
 
756
+ if ( /\<source/.test(layoutAssets[i]) ) {
757
+ if ( /type\=\"image/.test(layoutAssets[i]) ) {
758
+ type = 'image';
759
+ }
760
+
761
+ tag = 'source';
762
+ }
763
+
764
+ if ( /\<script/.test(layoutAssets[i]) ) {
765
+ type = 'javascript';
766
+ tag = 'script';
767
+ }
768
+
693
769
  domain = null;
770
+ let isEncodedContent = false;
771
+ // repsonsive images
772
+ // https://html.spec.whatwg.org/multipage/semantics.html#attr-link-imagesrcset
773
+ let srcset = null;
774
+ // https://html.spec.whatwg.org/multipage/semantics.html#attr-link-imagesizes
775
+ let sizes = null;
776
+ let urlArr = null;
694
777
  try {
695
- url = layoutAssets[i].match(/(src|href)\=(\".*?\"|\'.*?\')/)[0];
778
+ urlArr = layoutAssets[i].match(/(src|href|srcset)\=(\".*?\"|\'.*?\')/g);
779
+ for (let u=0, uLen=urlArr.length; u<uLen; u++) {
780
+ if ( /data\:/.test(urlArr[u]) ) {
781
+ isEncodedContent = true;
782
+ break;
783
+ }
784
+ if ( /^srcset\=/.test(urlArr[u]) ) {
785
+ srcset = urlArr[u]
786
+ .replace(/((src|href|srcset)\=\"|(src|href|srcset)\=\')/g, '')
787
+ .replace(/\"/g, '');
788
+ if ( /source/i.test(tag) ) {
789
+ sourceTagSrcSetStr += srcset + ','
790
+ }
791
+ }
792
+ if ( /^(src|href)\=/.test(urlArr[u]) ) {
793
+ url = urlArr[u]
794
+ .replace(/((src|href|srcset)\=\"|(src|href|srcset)\=\')/g, '')
795
+ .replace(/\"/g, '');
796
+ }
797
+ }
798
+ if ( isEncodedContent ) { // ignoring "data:..."
799
+ continue
800
+ }
801
+ // url = urlArr[0];
696
802
  } catch (err) {
697
- console.warn('Problem with this asset ('+ i +'/'+ len +'): '+ layoutAssets[i].substr(0, 80) +'...');
803
+ console.warn('Problem with this asset ('+ i +'/'+ len +'): '+ layoutAssets[i].substring(0, 80) +'...');
698
804
  continue;
699
805
  }
700
806
 
701
-
702
- if ( /data\:/.test(url) ) { // ignoring "data:..."
703
- continue
807
+ if ( /source/i.test(tag) ) {
808
+ continue;
704
809
  }
810
+
811
+
812
+ // if ( /data\:/.test(url) ) { // ignoring "data:..."
813
+ // continue
814
+ // }
705
815
  //url = url.replace(/((src|href)\=\"|(src|href)\=\'|\"|\')/g, '');
706
- url = url.replace(/((src|href)\=\"|(src|href)\=\')/g, '');
816
+ // url = url
817
+ // .replace(/((src|href|srcset)\=\"|(src|href|srcset)\=\')/g, '')
818
+ // .replace(/\"/g, '')
819
+ // ;
707
820
  if ( !/^\{\{/.test(url) ) {
708
821
  url = url.replace(/(\"|\')/g, '');
709
822
  }
710
- if (swig && /^\{\{/.test(url) )
823
+ if (swig && /^\{\{/.test(url) ) {
711
824
  url = swig.compile(url, swig.getOptions())(data);
825
+ }
712
826
 
713
827
  if (!/(\:\/\/|^\/\/)/.test(url) ) {
714
828
  filename = getAssetFilenameFromUrl(bundleConf, url);
@@ -728,7 +842,7 @@ function Server(options) {
728
842
  isAvailable = ( /404/.test(filename) ) ? false : true;
729
843
  if ( isAvailable ) {
730
844
  try {
731
- ext = url.substr(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/)[0];
845
+ ext = url.substring(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/)[0];
732
846
  } catch(err) {
733
847
 
734
848
  console.warn('No extension found for `'+ filename +'`\n'+ err.stack );
@@ -739,15 +853,41 @@ function Server(options) {
739
853
 
740
854
  assets[key] = {
741
855
  type : type,
856
+ as : asType,
742
857
  url : url,
743
858
  ext : ext,
744
- mime : (!ext) ? 'NA' : (bundleConf.server.coreConfiguration.mime[ext.substr(1)] || 'NA'),
859
+ mime : (!ext) ? 'NA' : (bundleConf.server.coreConfiguration.mime[ext.substring(1)] || 'NA'),
745
860
  filename : ( /404/.test(filename) ) ? 'not found' : filename,
746
861
  isAvailable : isAvailable
747
862
  };
748
863
 
749
- if (domain)
864
+ //sourceTagSrcSetStr
865
+ if (sourceTagSrcSetStr.length > 0) {
866
+ assets[key]['imagesrcset'] = sourceTagSrcSetStr.substring(0, sourceTagSrcSetStr.length-1);
867
+ // reset
868
+ sourceTagSrcSetStr = '';
869
+ }
870
+
871
+ if (srcset) {
872
+ if ( typeof(assets[key]['imagesrcset']) != 'undefined' ) {
873
+ assets[key]['imagesrcset'] += ', '+ srcset;
874
+ } else {
875
+ assets[key]['imagesrcset'] = srcset;
876
+ }
877
+
878
+ }
879
+
880
+ if (sizes) {
881
+ if ( typeof(assets[key]['imagesizes']) != 'undefined' ) {
882
+ assets[key]['imagesizes'] += ', '+ sizes;
883
+ } else {
884
+ assets[key]['imagesizes'] = sizes;
885
+ }
886
+ }
887
+
888
+ if (domain) {
750
889
  assets[key].domain = domain;
890
+ }
751
891
 
752
892
  if ( type == 'stylesheet' && !/not found/.test(assets[key].filename) ) {
753
893
  cssFiles.push(assets[key].filename)
@@ -873,14 +1013,14 @@ function Server(options) {
873
1013
  //key = (( /404/.test(filename) ) ? '[404]' : '[200]') +' '+ url;
874
1014
  key = url;
875
1015
  isAvailable = ( /404/.test(filename) ) ? false : true;
876
- ext = url.substr(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/)[0];
1016
+ ext = url.substring(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/)[0];
877
1017
  assets[key] = {
878
1018
  referrer : cssFiles[i],
879
1019
  definition : definition,
880
1020
  type : type,
881
1021
  url : url,
882
1022
  ext : ext,
883
- mime : bundleConf.server.coreConfiguration.mime[ext.substr(1)] || 'NA',
1023
+ mime : bundleConf.server.coreConfiguration.mime[ext.substring(1)] || 'NA',
884
1024
  filename : ( /404/.test(filename) ) ? 'not found' : filename
885
1025
  };
886
1026
 
@@ -997,8 +1137,10 @@ function Server(options) {
997
1137
  if ( typeof(request.headers.origin) != 'undefined' ) {
998
1138
  authority = request.headers.origin;
999
1139
  } else if (request.headers.referer) {
1000
- referer = request.headers.referer.match(/^[https://|http://][a-z0-9-_.:/]+\//)[0];
1001
- referer = referer.substring(0, referer.length-1);
1140
+ referer = request.headers.referer.match(/^[https://|http://][a-z0-9-_.:/]+\//);
1141
+ if (Array.isArray(referer) && referer.length > 0) {
1142
+ referer = referer[0].substring(0, referer.length-1);
1143
+ }
1002
1144
  }
1003
1145
 
1004
1146
  // access-control-allow-origin settings
@@ -1035,8 +1177,8 @@ function Server(options) {
1035
1177
  return name
1036
1178
  }
1037
1179
 
1038
- var env = self.conf.env
1039
- , scope = self.conf.scope
1180
+ var env = self.conf.env || self.env
1181
+ , scope = self.conf.scope || self.scope
1040
1182
  ;
1041
1183
 
1042
1184
  for (let i=0, len=matched.length; i<len; ++i) {
@@ -1054,6 +1196,9 @@ function Server(options) {
1054
1196
  project = arr[0];
1055
1197
  env = (arr[1]) ? arr[1] : env;
1056
1198
  }
1199
+ if ( typeof(self.conf[bundle]) == 'undefined' ) {
1200
+ continue;
1201
+ }
1057
1202
  scheme = self.conf[bundle][env].server.scheme;
1058
1203
  hostname = ( !self.conf[bundle][env].hostname ) ? self.conf[bundle][env].server.scheme + '://' + self.conf[bundle][env].host + ':' + self.conf[bundle][env].server.port : self.conf[bundle][env].hostname;
1059
1204
  name = name.replace(oldHost, hostname);
@@ -1122,13 +1267,13 @@ function Server(options) {
1122
1267
  }
1123
1268
 
1124
1269
  this.onHttp2Stream = function(stream, headers, response) {
1125
- var header = null
1126
- , isWebroot = false
1127
- , pathname = null
1128
- , asset = null
1129
- , assets = this._options.template.assets
1130
- , conf = this._options.conf
1131
- , cacheless = conf.cacheless
1270
+ var header = null
1271
+ , isWebroot = false
1272
+ , pathname = null
1273
+ , asset = null
1274
+ , assets = this._options.template.assets
1275
+ , conf = this._options.conf
1276
+ , isCacheless = conf.isCacheless
1132
1277
  ;
1133
1278
 
1134
1279
 
@@ -1157,7 +1302,17 @@ function Server(options) {
1157
1302
  ) ? true: false
1158
1303
  ;
1159
1304
 
1160
- if (!stream.pushAllowed) {
1305
+ if (!stream.pushAllowed ) {
1306
+
1307
+ // Fix added for static sites
1308
+ if (
1309
+ !assets[ url ]
1310
+ ||
1311
+ !assets[ url ].isBinary && !assets[ url ].isHandler
1312
+ ) {
1313
+ return;
1314
+ }
1315
+
1161
1316
  asset = {
1162
1317
  url : url,
1163
1318
  filename : assets[ url ].filename,
@@ -1203,6 +1358,7 @@ function Server(options) {
1203
1358
  , header
1204
1359
  //, { onError }
1205
1360
  );
1361
+
1206
1362
  } else {
1207
1363
  stream.respond(header);
1208
1364
  stream.end();
@@ -1227,7 +1383,7 @@ function Server(options) {
1227
1383
  ':status': 301
1228
1384
  };
1229
1385
 
1230
- if (cacheless) {
1386
+ if (isCacheless) {
1231
1387
  header['cache-control'] = 'no-cache, no-store, must-revalidate';
1232
1388
  header['pragma'] = 'no-cache';
1233
1389
  header['expires'] = '0';
@@ -1300,7 +1456,7 @@ function Server(options) {
1300
1456
  header['content-length'] = fs.statSync(assets[ url ].filename).size;
1301
1457
  }
1302
1458
 
1303
- if (cacheless) {
1459
+ if (isCacheless) {
1304
1460
  // source maps integration for javascript & css
1305
1461
  if ( /(.js|.css)$/.test(asset.filename) && fs.existsSync(asset.filename +'.map') ) {
1306
1462
  //pathname = asset.filename +'.map';
@@ -1389,7 +1545,7 @@ function Server(options) {
1389
1545
  self._options.conf = bundleConf
1390
1546
  }
1391
1547
 
1392
- var cacheless = bundleConf.cacheless;
1548
+ var isCacheless = bundleConf.isCacheless;
1393
1549
  // by default
1394
1550
  var filename = bundleConf.publicPath + pathname;
1395
1551
  var isFilenameDir = null
@@ -1417,7 +1573,6 @@ function Server(options) {
1417
1573
  var key = pathname.replace(pathname.split('/').splice(-1), '');
1418
1574
  for ( ; s < sLen; ++s ) {
1419
1575
  if ( bundleConf.staticResources[s] == key ) {
1420
- // if ( eval('/^' + bundleConf.staticResources[s].replace(/\//g,'\\/') +'/').test(pathname) ) {
1421
1576
  filename = bundleConf.content.statics[ bundleConf.staticResources[s] ] +'/'+ pathname.replace(bundleConf.staticResources[s], '');
1422
1577
  break;
1423
1578
  }
@@ -1431,9 +1586,11 @@ function Server(options) {
1431
1586
 
1432
1587
 
1433
1588
  filename = decodeURIComponent(filename);
1434
- fs.exists(filename, function onStaticExists(exist) {
1589
+ let filenameObj = new _(filename, true);
1590
+ filenameObj.exists(function onStaticExists(exists) {
1591
+ // fs.exists(filename, function onStaticExists(exists) {
1435
1592
 
1436
- if (!exist) {
1593
+ if (!exists) {
1437
1594
  return throwError(response, 404, 'Page not found: \n' + pathname, next);
1438
1595
  }
1439
1596
 
@@ -1446,48 +1603,49 @@ function Server(options) {
1446
1603
  if ( !fs.existsSync(filename) ) {
1447
1604
  throwError(response, 403, 'Forbidden: \n' + pathname, next);
1448
1605
  return;
1449
- } else {
1450
- var ext = 'html';
1451
- if ( /http\/2/.test(protocol) ) {
1452
- header = {
1453
- ':status': 301,
1454
- 'location': request.url,
1455
- 'content-type': bundleConf.server.coreConfiguration.mime[ext]+'; charset='+ bundleConf.encoding
1456
- };
1606
+ }
1457
1607
 
1458
- if (cacheless) {
1459
- header['cache-control'] = 'no-cache, no-store, must-revalidate';
1460
- header['pragma'] = 'no-cache';
1461
- header['expires'] = '0';
1462
- }
1463
- request = checkPreflightRequest(request, response);
1464
- header = completeHeaders(header, request, response);
1608
+ var ext = 'html';
1609
+ if ( /http\/2/.test(protocol) ) {
1610
+ header = {
1611
+ ':status': 301,
1612
+ 'location': request.url,
1613
+ 'content-type': bundleConf.server.coreConfiguration.mime[ext]+'; charset='+ bundleConf.encoding
1614
+ };
1465
1615
 
1466
- if (!stream.destroyed) {
1467
- stream.respond(header);
1468
- stream.end();
1469
- }
1616
+ if (isCacheless) {
1617
+ header['cache-control'] = 'no-cache, no-store, must-revalidate';
1618
+ header['pragma'] = 'no-cache';
1619
+ header['expires'] = '0';
1620
+ }
1621
+ request = checkPreflightRequest(request, response);
1622
+ header = completeHeaders(header, request, response);
1470
1623
 
1471
- } else {
1472
- response.setHeader('location', request.url);
1473
- request = checkPreflightRequest(request, response);
1474
- completeHeaders(null, request, response);
1475
- if (cacheless) {
1476
- response.writeHead(301, {
1477
- 'cache-control': 'no-cache, no-store, must-revalidate', // preventing browsers from using cache
1478
- 'pragma': 'no-cache',
1479
- 'expires': '0',
1480
- 'content-type': bundleConf.server.coreConfiguration.mime[ext]
1481
- });
1482
- }
1483
- response.end()
1624
+ if (!stream.destroyed) {
1625
+ stream.respond(header);
1626
+ stream.end();
1484
1627
  }
1628
+
1629
+ } else {
1630
+ response.setHeader('location', request.url);
1631
+ request = checkPreflightRequest(request, response);
1632
+ completeHeaders(null, request, response);
1633
+ if (isCacheless) {
1634
+ response.writeHead(301, {
1635
+ 'cache-control': 'no-cache, no-store, must-revalidate', // preventing browsers from using cache
1636
+ 'pragma': 'no-cache',
1637
+ 'expires': '0',
1638
+ 'content-type': bundleConf.server.coreConfiguration.mime[ext]
1639
+ });
1640
+ }
1641
+ response.end()
1485
1642
  }
1643
+
1486
1644
  return;
1487
1645
  }
1488
1646
 
1489
1647
 
1490
- if (cacheless) {
1648
+ if (isCacheless) {
1491
1649
  delete require.cache[require.resolve(filename)];
1492
1650
  }
1493
1651
 
@@ -1537,8 +1695,12 @@ function Server(options) {
1537
1695
  request.url = ( ext != null && typeof(ext[0]) != 'undefined' ) ? request.url : request.url + 'index.html';
1538
1696
 
1539
1697
  self._responseHeaders = response.getHeaders();
1540
- if (!isBinary && typeof(self._options.template.assets[request.url]) == 'undefined')
1698
+ if (
1699
+ !isBinary
1700
+ && typeof(self._options.template.assets[request.url]) == 'undefined'
1701
+ ) {
1541
1702
  self._options.template.assets = getAssets(bundleConf, file);
1703
+ }
1542
1704
 
1543
1705
  if (
1544
1706
  typeof(self._options.template.assets[request.url]) == 'undefined'
@@ -1603,7 +1765,7 @@ function Server(options) {
1603
1765
  'location': request.url
1604
1766
  };
1605
1767
 
1606
- if (cacheless) {
1768
+ if (isCacheless) {
1607
1769
  header['cache-control'] = 'no-cache, no-store, must-revalidate';
1608
1770
  header['pragma'] = 'no-cache';
1609
1771
  header['expires'] = '0';
@@ -1674,11 +1836,11 @@ function Server(options) {
1674
1836
  'content-type': contentType + '; charset='+ bundleConf.encoding
1675
1837
  };
1676
1838
 
1677
- if (cacheless) {
1839
+ if (isCacheless) {
1678
1840
  // source maps integration for javascript & css
1679
1841
  if ( /(.js|.css)$/.test(filename) && fs.existsSync(filename +'.map') && !/sourceMappingURL/.test(file) ) {
1680
1842
  //pathname = pathname +'.map';
1681
- pathname = webroot + pathname.substr(1) +'.map';
1843
+ pathname = webroot + pathname.substring(1) +'.map';
1682
1844
  // serve without cache
1683
1845
  header['X-SourceMap'] = pathname;
1684
1846
  header['cache-control'] = 'no-cache, no-store, must-revalidate';
@@ -1708,11 +1870,11 @@ function Server(options) {
1708
1870
  response.setHeader('content-length', fs.statSync(filename).size);
1709
1871
  }
1710
1872
 
1711
- if (cacheless) {
1873
+ if (isCacheless) {
1712
1874
  // source maps integration for javascript & css
1713
1875
  if ( /(.js|.css)$/.test(filename) && fs.existsSync(filename +'.map') && !/sourceMappingURL/.test(file) ) {
1714
1876
  //pathname = pathname +'.map'
1715
- pathname = webroot + pathname.substr(1) +'.map';
1877
+ pathname = webroot + pathname.substring(1) +'.map';
1716
1878
  response.setHeader("X-SourceMap", pathname)
1717
1879
  }
1718
1880
 
@@ -1753,7 +1915,8 @@ function Server(options) {
1753
1915
  });
1754
1916
 
1755
1917
 
1756
- })
1918
+ });
1919
+ filenameObj = null;
1757
1920
  }
1758
1921
 
1759
1922
 
@@ -1765,6 +1928,28 @@ function Server(options) {
1765
1928
  // catch all (request urls)
1766
1929
  self.instance.all('*', function onInstance(request, response, next) {
1767
1930
 
1931
+ // Caching = [...]
1932
+ // TODO - handle this through a middleware
1933
+ /**
1934
+ * var cacheIndex = ['/api/document/get/b47c4dd3-f7c4-44b2-b1fb-401948be1ca4'].indexOf(request.url)
1935
+ * if ( cacheIndex > -1) {
1936
+ * // return caching[cacheIndex].content
1937
+ * }
1938
+ */
1939
+
1940
+ // Retrieving cached route
1941
+ // var cachedUrls = ['/'];
1942
+ // if (cachedUrls.indexOf(request.url) > -1) {
1943
+ // request.routing = JSON.parse('{"method":"GET","namespace":"home","url":"/","rule":"home@public","param":{"control":"home","file":"../home"},"middleware":["middlewares.maintenance.check"],"bundle":"public","isXMLRequest":false,"isWithCredentials":false}');
1944
+ // var headers = JSON.parse('{"x-powered-by":"Gina I/O - v0.1.6-alpha.94","access-control-allow-headers":"X-Requested-With, Content-Type","access-control-allow-methods":"GET","access-control-allow-credentials":true,"vary":"Origin","accept-language":"en-US,en;q=0.8,fr;q=0.6"}');
1945
+ // for (let h in headers) {
1946
+ // response.setHeader(h, headers[h]);
1947
+ // }
1948
+
1949
+ // return local.router.route(request, response, next, request.routing);
1950
+ // }
1951
+
1952
+
1768
1953
 
1769
1954
  request.setEncoding(self.conf[self.appName][self.env].encoding);
1770
1955
  // be carfull, if you are using jQuery + cross domain, you have to set the header manually in your $.ajax query -> headers: {'X-Requested-With': 'XMLHttpRequest'}
@@ -1864,7 +2049,7 @@ function Server(options) {
1864
2049
  if ( typeof(ext) != 'undefined' && ext != null) {
1865
2050
  ext = ext[0];
1866
2051
  // if image with `@` found
1867
- if ( /^image/i.test(self.conf[self.appName][self.env].server.coreConfiguration.mime[ext.substr(1)]) ) {
2052
+ if ( /^image/i.test(self.conf[self.appName][self.env].server.coreConfiguration.mime[ext.substring(1)]) ) {
1868
2053
  isImage = true
1869
2054
  }
1870
2055
  }
@@ -1873,7 +2058,7 @@ function Server(options) {
1873
2058
  // and must not be an email
1874
2059
  && !/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(request.url)
1875
2060
  // and must be handled by mime.types
1876
- && typeof(self.conf[self.appName][self.env].server.coreConfiguration.mime[ext.substr(1)]) != 'undefined'
2061
+ && typeof(self.conf[self.appName][self.env].server.coreConfiguration.mime[ext.substring(1)]) != 'undefined'
1877
2062
  ||
1878
2063
  ext != null
1879
2064
  && isImage
@@ -1899,7 +2084,7 @@ function Server(options) {
1899
2084
 
1900
2085
  if (
1901
2086
  staticProps.isStaticFilename && staticsArr.indexOf(request.url) > -1
1902
- || staticProps.isStaticFilename && staticsArr.indexOf( request.url.replace(request.url.substr(request.url.lastIndexOf('/')+1), '') ) > -1
2087
+ || staticProps.isStaticFilename && staticsArr.indexOf( request.url.replace(request.url.substring(request.url.lastIndexOf('/')+1), '') ) > -1
1903
2088
  || staticProps.isStaticFilename && new RegExp('^'+ staticProps.firstLevel).test(request.url)
1904
2089
  || /\/$/.test(request.url) && !isWebrootHandledByRouting && !/\/engine\.io\//.test(request.url)
1905
2090
  ) {
@@ -2067,11 +2252,14 @@ function Server(options) {
2067
2252
  'method': 'POST',
2068
2253
  'bundle' : self.appName
2069
2254
  };
2070
- var busboy = new Busboy({ headers: request.headers });
2255
+ var busboy = Busboy({ headers: request.headers });
2071
2256
 
2072
2257
  // busboy.on('field', function(fieldname, val, fieldnameTruncated, valTruncated) {
2073
2258
  // console.log('Field [' + fieldname + ']: value: ' + inspect(val));
2074
2259
  // });
2260
+
2261
+ // Attention: on busboy upgrade, we needs to adapt `busboy/lib/types/multipart.js`
2262
+ // For this, check the emit method
2075
2263
  busboy.on('file', function(fieldname, file, filename, encoding, mimetype, group) {
2076
2264
 
2077
2265
  file._dataLen = 0;
@@ -2087,7 +2275,7 @@ function Server(options) {
2087
2275
  && opt.groups[group].allowedExtensions != '*'
2088
2276
  ) {
2089
2277
  var ext = opt.groups[group].allowedExtensions;
2090
- var fileExt = filename.substr(filename.lastIndexOf('.')+1)
2278
+ var fileExt = filename.substring(filename.lastIndexOf('.')+1)
2091
2279
  if ( !Array.isArray(ext) ) {
2092
2280
  ext = [ext]
2093
2281
  }
@@ -2243,12 +2431,12 @@ function Server(options) {
2243
2431
  // get rid of encoding issues
2244
2432
  try {
2245
2433
  if ( !/multipart\/form-data;/.test(request.headers['content-type']) ) {
2246
- if ( /application\/x\-www\-form\-urlencoded/.test(request.headers['content-type']) && /\+/.test(request.body) ) {
2434
+ if ( !/application\/x\-www\-form\-urlencoded/.test(request.headers['content-type']) && /\+/.test(request.body) ) {
2247
2435
  request.body = request.body.replace(/\+/g, ' ');
2248
2436
  }
2249
2437
 
2250
- if ( request.body.substr(0,1) == '?')
2251
- request.body = request.body.substr(1);
2438
+ if ( request.body.substring(0,1) == '?')
2439
+ request.body = request.body.substring(1);
2252
2440
 
2253
2441
  try {
2254
2442
  bodyStr = decodeURIComponent(request.body); // it is already a string for sure
@@ -2399,8 +2587,8 @@ function Server(options) {
2399
2587
  request.body = request.body.replace(/\+/g, ' ');
2400
2588
  }
2401
2589
 
2402
- if ( request.body.substr(0,1) == '?')
2403
- request.body = request.body.substr(1);
2590
+ if ( request.body.substring(0,1) == '?')
2591
+ request.body = request.body.substring(1);
2404
2592
 
2405
2593
  // false & true case
2406
2594
  try {
@@ -2521,8 +2709,10 @@ function Server(options) {
2521
2709
 
2522
2710
  var config = new Config();
2523
2711
  config.setBundles(self.bundles);
2524
- var conf = config.getInstance(); // for all loaded bundles
2525
- if ( typeof(conf) != 'undefined') {//for cacheless mode
2712
+ // for all loaded bundles
2713
+ var conf = config.getInstance();
2714
+ //for cacheless mode
2715
+ if ( typeof(conf) != 'undefined') {
2526
2716
  self.conf = conf;
2527
2717
  }
2528
2718
 
@@ -2537,7 +2727,7 @@ function Server(options) {
2537
2727
  if (self.bundles.indexOf(b) < 0) continue;
2538
2728
  if ( typeof(conf[b][self.env].content) != 'undefined' && typeof(conf[b][self.env].content.statics) != 'undefined' && conf[b][self.env].content.statics.count() > 0 ) {
2539
2729
  for (let s in conf[b][self.env].content.statics) {
2540
- s = (s.substr(0,1) == '/') ? s.substr(1) : s;
2730
+ s = (s.substring(0,1) == '/') ? s.substring(1) : s;
2541
2731
  if ( (new RegExp('^/'+s)).test(pathname) ) {
2542
2732
  bundle = b;
2543
2733
  break end
@@ -2572,18 +2762,18 @@ function Server(options) {
2572
2762
  }
2573
2763
 
2574
2764
  var onBundleConfigLoaded = function(bundle, options) {
2575
- var err = options.err
2576
- , cacheless = options.config.isCacheless()
2577
- , pathname = options.pathname
2578
- , req = options.req
2579
- , res = options.res
2580
- , config = options.conf
2581
- , next = options.next
2582
- , callback = options.callback
2765
+ var err = options.err
2766
+ , isCacheless = options.config.isCacheless()
2767
+ , pathname = options.pathname
2768
+ , req = options.req
2769
+ , res = options.res
2770
+ , config = options.conf
2771
+ , next = options.next
2772
+ , callback = options.callback
2583
2773
  ;
2584
2774
 
2585
2775
  //Reloading assets & files.
2586
- // if (!cacheless) { // all but dev & debug
2776
+ // if (!isCacheless) { // all but dev & debug
2587
2777
  callback(err, bundle, pathname, options.config, req, res, next)
2588
2778
  // } else {
2589
2779
  // config.refresh(bundle, function(err, routing) {
@@ -2706,7 +2896,7 @@ function Server(options) {
2706
2896
  , isRoute = {}
2707
2897
  , withViews = hasViews(bundle)
2708
2898
  , router = local.router
2709
- , cacheless = config.isCacheless()
2899
+ , isCacheless = config.isCacheless()
2710
2900
  , wroot = null
2711
2901
  ;
2712
2902
 
@@ -2736,6 +2926,11 @@ function Server(options) {
2736
2926
  var isMethodAllowed = null, hostname = null;
2737
2927
  out:
2738
2928
  for (let name in routing) {
2929
+ // ignoring routes out of scope
2930
+ if ( routing[name].scopes.indexOf(process.env.NODE_SCOPE) < 0 ) {
2931
+ continue;
2932
+ }
2933
+
2739
2934
  if ( typeof(routing[name]['param']) == 'undefined' ) {
2740
2935
  break;
2741
2936
  }
@@ -2961,11 +3156,11 @@ function Server(options) {
2961
3156
  , ext = null
2962
3157
  , isHtmlContent = false
2963
3158
  , hasCustomErrorFile = false
2964
- , eCode = code.toString().substr(0,1) + 'xx'
3159
+ , eCode = code.toString().substring(0,1) + 'xx'
2965
3160
  ;
2966
- var extArr = url.substr(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/);
3161
+ var extArr = url.substring(url.lastIndexOf('.')).match(/(\.[A-Za-z0-9]+)/);
2967
3162
  if (extArr) {
2968
- ext = extArr[0].substr(1);
3163
+ ext = extArr[0].substring(1);
2969
3164
  }
2970
3165
  if ( !ext || /^(html|htm)$/i.test(ext) ) {
2971
3166
  isHtmlContent = true;