ventojs 0.10.2 → 0.12.0

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/README.md +35 -93
  2. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/assert/assert.js +1 -1
  3. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/assert/assertion_error.js +1 -1
  4. package/esm/deps/deno.land/std@0.219.1/html/entities.d.ts +39 -0
  5. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/html/entities.js +14 -15
  6. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/html/mod.d.ts +1 -1
  7. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/html/mod.js +2 -2
  8. package/esm/deps/deno.land/std@0.219.1/path/_common/assert_path.d.ts +1 -0
  9. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/assert_path.js +1 -1
  10. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/basename.js +1 -1
  11. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/common.js +9 -9
  12. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/constants.js +1 -1
  13. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/dirname.js +1 -1
  14. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/format.js +1 -1
  15. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/from_file_url.js +1 -1
  16. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/glob_to_reg_exp.js +4 -2
  17. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/normalize.js +1 -1
  18. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/normalize_string.js +1 -1
  19. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/relative.js +1 -1
  20. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/strip_trailing_separators.js +1 -1
  21. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/to_file_url.js +1 -1
  22. package/esm/deps/deno.land/std@0.219.1/path/_interface.js +3 -0
  23. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_os.js +1 -1
  24. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/basename.js +1 -1
  25. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/common.js +3 -3
  26. package/esm/deps/deno.land/std@0.219.1/path/constants.d.ts +3 -0
  27. package/esm/deps/deno.land/std@0.219.1/path/constants.js +6 -0
  28. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/dirname.js +1 -1
  29. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/extname.js +1 -1
  30. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/format.d.ts +1 -1
  31. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/format.js +1 -1
  32. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/from_file_url.js +1 -1
  33. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/glob_to_regexp.d.ts +2 -1
  34. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/glob_to_regexp.js +1 -1
  35. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/is_absolute.js +1 -1
  36. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/is_glob.js +1 -1
  37. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/join.js +1 -1
  38. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/join_globs.d.ts +1 -0
  39. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/join_globs.js +1 -1
  40. package/esm/deps/deno.land/std@0.219.1/path/mod.d.ts +56 -0
  41. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/mod.js +3 -8
  42. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/normalize.js +1 -1
  43. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/normalize_glob.d.ts +1 -0
  44. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/normalize_glob.js +1 -1
  45. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/parse.js +1 -1
  46. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/_util.js +1 -1
  47. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/basename.js +1 -1
  48. package/esm/deps/deno.land/{std@0.210.0/path/windows → std@0.219.1/path/posix}/common.js +3 -3
  49. package/esm/deps/deno.land/std@0.219.1/path/posix/constants.d.ts +3 -0
  50. package/esm/deps/deno.land/std@0.219.1/path/posix/constants.js +5 -0
  51. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/dirname.js +1 -1
  52. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/extname.js +1 -1
  53. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/format.js +1 -1
  54. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/posix/from_file_url.d.ts +1 -1
  55. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/from_file_url.js +2 -2
  56. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/glob_to_regexp.d.ts +1 -1
  57. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/glob_to_regexp.js +1 -1
  58. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/is_absolute.js +1 -1
  59. package/esm/deps/deno.land/{std@0.210.0/path/windows → std@0.219.1/path/posix}/is_glob.js +1 -1
  60. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/join.js +1 -1
  61. package/esm/deps/deno.land/{std@0.210.0/path/windows → std@0.219.1/path/posix}/join_globs.d.ts +2 -1
  62. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/join_globs.js +3 -3
  63. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/mod.d.ts +1 -3
  64. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/mod.js +2 -4
  65. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/normalize.js +1 -1
  66. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/posix/normalize_glob.d.ts +2 -1
  67. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/normalize_glob.js +3 -3
  68. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/parse.d.ts +1 -1
  69. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/parse.js +1 -1
  70. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/relative.js +1 -1
  71. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/resolve.js +1 -1
  72. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/to_file_url.d.ts +1 -1
  73. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/to_file_url.js +2 -2
  74. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/to_namespaced_path.js +1 -1
  75. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/relative.js +1 -1
  76. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/resolve.js +1 -1
  77. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/to_file_url.js +1 -1
  78. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/to_namespaced_path.js +1 -1
  79. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/_util.js +1 -1
  80. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/basename.js +1 -1
  81. package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.219.1/path/windows}/common.js +3 -3
  82. package/esm/deps/deno.land/std@0.219.1/path/windows/constants.d.ts +3 -0
  83. package/esm/deps/deno.land/std@0.219.1/path/windows/constants.js +5 -0
  84. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/dirname.js +1 -1
  85. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/extname.js +1 -1
  86. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/format.js +1 -1
  87. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/windows/from_file_url.d.ts +1 -1
  88. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/from_file_url.js +2 -2
  89. package/{script/deps/deno.land/std@0.210.0/path/posix → esm/deps/deno.land/std@0.219.1/path/windows}/glob_to_regexp.d.ts +1 -1
  90. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/glob_to_regexp.js +1 -1
  91. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/is_absolute.js +1 -1
  92. package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.219.1/path/windows}/is_glob.js +1 -1
  93. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/join.js +1 -1
  94. package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.219.1/path/windows}/join_globs.d.ts +2 -1
  95. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/join_globs.js +3 -3
  96. package/{script/deps/deno.land/std@0.210.0/path/posix → esm/deps/deno.land/std@0.219.1/path/windows}/mod.d.ts +1 -3
  97. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/mod.js +2 -4
  98. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/normalize.js +1 -1
  99. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/windows/normalize_glob.d.ts +2 -1
  100. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/normalize_glob.js +3 -3
  101. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/parse.d.ts +1 -1
  102. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/parse.js +1 -1
  103. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/relative.js +1 -1
  104. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/resolve.js +1 -1
  105. package/{script/deps/deno.land/std@0.210.0 → esm/deps/deno.land/std@0.219.1}/path/windows/to_file_url.d.ts +1 -1
  106. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/to_file_url.js +2 -2
  107. package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/to_namespaced_path.js +1 -1
  108. package/esm/deps/deno.land/x/astring@v1.8.6/src/astring.d.ts +109 -0
  109. package/esm/deps/deno.land/x/astring@v1.8.6/src/astring.js +1159 -0
  110. package/esm/deps.d.ts +6 -2
  111. package/esm/deps.js +5 -2
  112. package/esm/mod.d.ts +1 -0
  113. package/esm/mod.js +2 -0
  114. package/esm/plugins/auto_trim.d.ts +8 -0
  115. package/esm/plugins/auto_trim.js +36 -0
  116. package/esm/plugins/escape.js +2 -1
  117. package/esm/plugins/trim.d.ts +4 -0
  118. package/esm/plugins/trim.js +28 -0
  119. package/esm/plugins/unescape.js +2 -1
  120. package/esm/src/environment.d.ts +3 -0
  121. package/esm/src/environment.js +28 -7
  122. package/esm/src/tokenizer.js +6 -29
  123. package/esm/src/transformer.d.ts +1 -0
  124. package/esm/src/transformer.js +180 -0
  125. package/package.json +21 -8
  126. package/esm/deps/deno.land/std@0.210.0/html/entities.d.ts +0 -38
  127. package/esm/deps/deno.land/std@0.210.0/path/_common/assert_path.d.ts +0 -1
  128. package/esm/deps/deno.land/std@0.210.0/path/_interface.js +0 -3
  129. package/esm/deps/deno.land/std@0.210.0/path/common.d.ts +0 -13
  130. package/esm/deps/deno.land/std@0.210.0/path/glob_to_regexp.d.ts +0 -61
  131. package/esm/deps/deno.land/std@0.210.0/path/mod.d.ts +0 -28
  132. package/esm/deps/deno.land/std@0.210.0/path/normalize_glob.d.ts +0 -3
  133. package/esm/deps/deno.land/std@0.210.0/path/posix/from_file_url.d.ts +0 -12
  134. package/esm/deps/deno.land/std@0.210.0/path/posix/normalize_glob.d.ts +0 -3
  135. package/esm/deps/deno.land/std@0.210.0/path/posix/separator.d.ts +0 -2
  136. package/esm/deps/deno.land/std@0.210.0/path/posix/separator.js +0 -4
  137. package/esm/deps/deno.land/std@0.210.0/path/separator.d.ts +0 -2
  138. package/esm/deps/deno.land/std@0.210.0/path/separator.js +0 -5
  139. package/esm/deps/deno.land/std@0.210.0/path/windows/from_file_url.d.ts +0 -14
  140. package/esm/deps/deno.land/std@0.210.0/path/windows/glob_to_regexp.d.ts +0 -57
  141. package/esm/deps/deno.land/std@0.210.0/path/windows/mod.d.ts +0 -40
  142. package/esm/deps/deno.land/std@0.210.0/path/windows/normalize_glob.d.ts +0 -3
  143. package/esm/deps/deno.land/std@0.210.0/path/windows/separator.d.ts +0 -2
  144. package/esm/deps/deno.land/std@0.210.0/path/windows/separator.js +0 -4
  145. package/esm/deps/deno.land/std@0.210.0/path/windows/to_file_url.d.ts +0 -14
  146. package/script/_dnt.shims.d.ts +0 -5
  147. package/script/_dnt.shims.js +0 -65
  148. package/script/deps/deno.land/std@0.210.0/assert/assert.d.ts +0 -12
  149. package/script/deps/deno.land/std@0.210.0/assert/assert.js +0 -22
  150. package/script/deps/deno.land/std@0.210.0/assert/assertion_error.d.ts +0 -14
  151. package/script/deps/deno.land/std@0.210.0/assert/assertion_error.js +0 -22
  152. package/script/deps/deno.land/std@0.210.0/html/entities.d.ts +0 -38
  153. package/script/deps/deno.land/std@0.210.0/html/entities.js +0 -81
  154. package/script/deps/deno.land/std@0.210.0/html/mod.d.ts +0 -6
  155. package/script/deps/deno.land/std@0.210.0/html/mod.js +0 -24
  156. package/script/deps/deno.land/std@0.210.0/path/_common/assert_path.d.ts +0 -1
  157. package/script/deps/deno.land/std@0.210.0/path/_common/assert_path.js +0 -11
  158. package/script/deps/deno.land/std@0.210.0/path/_common/basename.d.ts +0 -3
  159. package/script/deps/deno.land/std@0.210.0/path/_common/basename.js +0 -46
  160. package/script/deps/deno.land/std@0.210.0/path/_common/common.d.ts +0 -1
  161. package/script/deps/deno.land/std@0.210.0/path/_common/common.js +0 -27
  162. package/script/deps/deno.land/std@0.210.0/path/_common/constants.d.ts +0 -39
  163. package/script/deps/deno.land/std@0.210.0/path/_common/constants.js +0 -49
  164. package/script/deps/deno.land/std@0.210.0/path/_common/dirname.d.ts +0 -1
  165. package/script/deps/deno.land/std@0.210.0/path/_common/dirname.js +0 -12
  166. package/script/deps/deno.land/std@0.210.0/path/_common/format.d.ts +0 -3
  167. package/script/deps/deno.land/std@0.210.0/path/_common/format.js +0 -24
  168. package/script/deps/deno.land/std@0.210.0/path/_common/from_file_url.d.ts +0 -2
  169. package/script/deps/deno.land/std@0.210.0/path/_common/from_file_url.js +0 -13
  170. package/script/deps/deno.land/std@0.210.0/path/_common/glob_to_reg_exp.d.ts +0 -28
  171. package/script/deps/deno.land/std@0.210.0/path/_common/glob_to_reg_exp.js +0 -239
  172. package/script/deps/deno.land/std@0.210.0/path/_common/normalize.d.ts +0 -1
  173. package/script/deps/deno.land/std@0.210.0/path/_common/normalize.js +0 -12
  174. package/script/deps/deno.land/std@0.210.0/path/_common/normalize_string.d.ts +0 -1
  175. package/script/deps/deno.land/std@0.210.0/path/_common/normalize_string.js +0 -81
  176. package/script/deps/deno.land/std@0.210.0/path/_common/relative.d.ts +0 -1
  177. package/script/deps/deno.land/std@0.210.0/path/_common/relative.js +0 -13
  178. package/script/deps/deno.land/std@0.210.0/path/_common/strip_trailing_separators.d.ts +0 -1
  179. package/script/deps/deno.land/std@0.210.0/path/_common/strip_trailing_separators.js +0 -23
  180. package/script/deps/deno.land/std@0.210.0/path/_common/to_file_url.d.ts +0 -1
  181. package/script/deps/deno.land/std@0.210.0/path/_common/to_file_url.js +0 -19
  182. package/script/deps/deno.land/std@0.210.0/path/_interface.d.ts +0 -26
  183. package/script/deps/deno.land/std@0.210.0/path/_interface.js +0 -4
  184. package/script/deps/deno.land/std@0.210.0/path/_os.d.ts +0 -3
  185. package/script/deps/deno.land/std@0.210.0/path/_os.js +0 -44
  186. package/script/deps/deno.land/std@0.210.0/path/basename.d.ts +0 -8
  187. package/script/deps/deno.land/std@0.210.0/path/basename.js +0 -21
  188. package/script/deps/deno.land/std@0.210.0/path/common.d.ts +0 -13
  189. package/script/deps/deno.land/std@0.210.0/path/common.js +0 -23
  190. package/script/deps/deno.land/std@0.210.0/path/dirname.d.ts +0 -5
  191. package/script/deps/deno.land/std@0.210.0/path/dirname.js +0 -16
  192. package/script/deps/deno.land/std@0.210.0/path/extname.d.ts +0 -6
  193. package/script/deps/deno.land/std@0.210.0/path/extname.js +0 -17
  194. package/script/deps/deno.land/std@0.210.0/path/format.d.ts +0 -6
  195. package/script/deps/deno.land/std@0.210.0/path/format.js +0 -16
  196. package/script/deps/deno.land/std@0.210.0/path/from_file_url.d.ts +0 -18
  197. package/script/deps/deno.land/std@0.210.0/path/from_file_url.js +0 -28
  198. package/script/deps/deno.land/std@0.210.0/path/glob_to_regexp.js +0 -69
  199. package/script/deps/deno.land/std@0.210.0/path/is_absolute.d.ts +0 -5
  200. package/script/deps/deno.land/std@0.210.0/path/is_absolute.js +0 -16
  201. package/script/deps/deno.land/std@0.210.0/path/is_glob.d.ts +0 -2
  202. package/script/deps/deno.land/std@0.210.0/path/is_glob.js +0 -32
  203. package/script/deps/deno.land/std@0.210.0/path/join.d.ts +0 -5
  204. package/script/deps/deno.land/std@0.210.0/path/join.js +0 -16
  205. package/script/deps/deno.land/std@0.210.0/path/join_globs.d.ts +0 -3
  206. package/script/deps/deno.land/std@0.210.0/path/join_globs.js +0 -15
  207. package/script/deps/deno.land/std@0.210.0/path/mod.d.ts +0 -28
  208. package/script/deps/deno.land/std@0.210.0/path/mod.js +0 -94
  209. package/script/deps/deno.land/std@0.210.0/path/normalize.d.ts +0 -7
  210. package/script/deps/deno.land/std@0.210.0/path/normalize.js +0 -18
  211. package/script/deps/deno.land/std@0.210.0/path/normalize_glob.js +0 -15
  212. package/script/deps/deno.land/std@0.210.0/path/parse.d.ts +0 -6
  213. package/script/deps/deno.land/std@0.210.0/path/parse.js +0 -16
  214. package/script/deps/deno.land/std@0.210.0/path/posix/_util.d.ts +0 -1
  215. package/script/deps/deno.land/std@0.210.0/path/posix/_util.js +0 -12
  216. package/script/deps/deno.land/std@0.210.0/path/posix/basename.d.ts +0 -8
  217. package/script/deps/deno.land/std@0.210.0/path/posix/basename.js +0 -22
  218. package/script/deps/deno.land/std@0.210.0/path/posix/common.js +0 -23
  219. package/script/deps/deno.land/std@0.210.0/path/posix/dirname.d.ts +0 -5
  220. package/script/deps/deno.land/std@0.210.0/path/posix/dirname.js +0 -40
  221. package/script/deps/deno.land/std@0.210.0/path/posix/extname.d.ts +0 -6
  222. package/script/deps/deno.land/std@0.210.0/path/posix/extname.js +0 -63
  223. package/script/deps/deno.land/std@0.210.0/path/posix/format.d.ts +0 -6
  224. package/script/deps/deno.land/std@0.210.0/path/posix/format.js +0 -15
  225. package/script/deps/deno.land/std@0.210.0/path/posix/from_file_url.js +0 -21
  226. package/script/deps/deno.land/std@0.210.0/path/posix/glob_to_regexp.js +0 -73
  227. package/script/deps/deno.land/std@0.210.0/path/posix/is_absolute.d.ts +0 -5
  228. package/script/deps/deno.land/std@0.210.0/path/posix/is_absolute.js +0 -16
  229. package/script/deps/deno.land/std@0.210.0/path/posix/is_glob.d.ts +0 -1
  230. package/script/deps/deno.land/std@0.210.0/path/posix/is_glob.js +0 -7
  231. package/script/deps/deno.land/std@0.210.0/path/posix/join.d.ts +0 -5
  232. package/script/deps/deno.land/std@0.210.0/path/posix/join.js +0 -30
  233. package/script/deps/deno.land/std@0.210.0/path/posix/join_globs.d.ts +0 -3
  234. package/script/deps/deno.land/std@0.210.0/path/posix/join_globs.js +0 -30
  235. package/script/deps/deno.land/std@0.210.0/path/posix/mod.js +0 -61
  236. package/script/deps/deno.land/std@0.210.0/path/posix/normalize.d.ts +0 -7
  237. package/script/deps/deno.land/std@0.210.0/path/posix/normalize.js +0 -29
  238. package/script/deps/deno.land/std@0.210.0/path/posix/normalize_glob.js +0 -20
  239. package/script/deps/deno.land/std@0.210.0/path/posix/parse.d.ts +0 -6
  240. package/script/deps/deno.land/std@0.210.0/path/posix/parse.js +0 -102
  241. package/script/deps/deno.land/std@0.210.0/path/posix/relative.d.ts +0 -7
  242. package/script/deps/deno.land/std@0.210.0/path/posix/relative.js +0 -98
  243. package/script/deps/deno.land/std@0.210.0/path/posix/resolve.d.ts +0 -5
  244. package/script/deps/deno.land/std@0.210.0/path/posix/resolve.js +0 -75
  245. package/script/deps/deno.land/std@0.210.0/path/posix/separator.d.ts +0 -2
  246. package/script/deps/deno.land/std@0.210.0/path/posix/separator.js +0 -7
  247. package/script/deps/deno.land/std@0.210.0/path/posix/to_file_url.d.ts +0 -12
  248. package/script/deps/deno.land/std@0.210.0/path/posix/to_file_url.js +0 -26
  249. package/script/deps/deno.land/std@0.210.0/path/posix/to_namespaced_path.d.ts +0 -5
  250. package/script/deps/deno.land/std@0.210.0/path/posix/to_namespaced_path.js +0 -14
  251. package/script/deps/deno.land/std@0.210.0/path/relative.d.ts +0 -12
  252. package/script/deps/deno.land/std@0.210.0/path/relative.js +0 -23
  253. package/script/deps/deno.land/std@0.210.0/path/resolve.d.ts +0 -5
  254. package/script/deps/deno.land/std@0.210.0/path/resolve.js +0 -18
  255. package/script/deps/deno.land/std@0.210.0/path/separator.d.ts +0 -2
  256. package/script/deps/deno.land/std@0.210.0/path/separator.js +0 -8
  257. package/script/deps/deno.land/std@0.210.0/path/to_file_url.d.ts +0 -18
  258. package/script/deps/deno.land/std@0.210.0/path/to_file_url.js +0 -28
  259. package/script/deps/deno.land/std@0.210.0/path/to_namespaced_path.d.ts +0 -5
  260. package/script/deps/deno.land/std@0.210.0/path/to_namespaced_path.js +0 -18
  261. package/script/deps/deno.land/std@0.210.0/path/windows/_util.d.ts +0 -3
  262. package/script/deps/deno.land/std@0.210.0/path/windows/_util.js +0 -21
  263. package/script/deps/deno.land/std@0.210.0/path/windows/basename.d.ts +0 -8
  264. package/script/deps/deno.land/std@0.210.0/path/windows/basename.js +0 -34
  265. package/script/deps/deno.land/std@0.210.0/path/windows/common.d.ts +0 -13
  266. package/script/deps/deno.land/std@0.210.0/path/windows/common.js +0 -23
  267. package/script/deps/deno.land/std@0.210.0/path/windows/dirname.d.ts +0 -5
  268. package/script/deps/deno.land/std@0.210.0/path/windows/dirname.js +0 -102
  269. package/script/deps/deno.land/std@0.210.0/path/windows/extname.d.ts +0 -6
  270. package/script/deps/deno.land/std@0.210.0/path/windows/extname.js +0 -72
  271. package/script/deps/deno.land/std@0.210.0/path/windows/format.d.ts +0 -6
  272. package/script/deps/deno.land/std@0.210.0/path/windows/format.js +0 -15
  273. package/script/deps/deno.land/std@0.210.0/path/windows/from_file_url.js +0 -30
  274. package/script/deps/deno.land/std@0.210.0/path/windows/glob_to_regexp.d.ts +0 -57
  275. package/script/deps/deno.land/std@0.210.0/path/windows/glob_to_regexp.js +0 -73
  276. package/script/deps/deno.land/std@0.210.0/path/windows/is_absolute.d.ts +0 -5
  277. package/script/deps/deno.land/std@0.210.0/path/windows/is_absolute.js +0 -31
  278. package/script/deps/deno.land/std@0.210.0/path/windows/is_glob.d.ts +0 -1
  279. package/script/deps/deno.land/std@0.210.0/path/windows/is_glob.js +0 -7
  280. package/script/deps/deno.land/std@0.210.0/path/windows/join.d.ts +0 -5
  281. package/script/deps/deno.land/std@0.210.0/path/windows/join.js +0 -76
  282. package/script/deps/deno.land/std@0.210.0/path/windows/join_globs.d.ts +0 -3
  283. package/script/deps/deno.land/std@0.210.0/path/windows/join_globs.js +0 -30
  284. package/script/deps/deno.land/std@0.210.0/path/windows/mod.d.ts +0 -40
  285. package/script/deps/deno.land/std@0.210.0/path/windows/mod.js +0 -61
  286. package/script/deps/deno.land/std@0.210.0/path/windows/normalize.d.ts +0 -7
  287. package/script/deps/deno.land/std@0.210.0/path/windows/normalize.js +0 -134
  288. package/script/deps/deno.land/std@0.210.0/path/windows/normalize_glob.js +0 -20
  289. package/script/deps/deno.land/std@0.210.0/path/windows/parse.d.ts +0 -6
  290. package/script/deps/deno.land/std@0.210.0/path/windows/parse.js +0 -163
  291. package/script/deps/deno.land/std@0.210.0/path/windows/relative.d.ts +0 -12
  292. package/script/deps/deno.land/std@0.210.0/path/windows/relative.js +0 -125
  293. package/script/deps/deno.land/std@0.210.0/path/windows/resolve.d.ts +0 -5
  294. package/script/deps/deno.land/std@0.210.0/path/windows/resolve.js +0 -170
  295. package/script/deps/deno.land/std@0.210.0/path/windows/separator.d.ts +0 -2
  296. package/script/deps/deno.land/std@0.210.0/path/windows/separator.js +0 -7
  297. package/script/deps/deno.land/std@0.210.0/path/windows/to_file_url.js +0 -35
  298. package/script/deps/deno.land/std@0.210.0/path/windows/to_namespaced_path.d.ts +0 -5
  299. package/script/deps/deno.land/std@0.210.0/path/windows/to_namespaced_path.js +0 -42
  300. package/script/deps.d.ts +0 -2
  301. package/script/deps.js +0 -28
  302. package/script/mod.d.ts +0 -9
  303. package/script/mod.js +0 -69
  304. package/script/package.json +0 -3
  305. package/script/plugins/echo.d.ts +0 -2
  306. package/script/plugins/echo.js +0 -16
  307. package/script/plugins/escape.d.ts +0 -2
  308. package/script/plugins/escape.js +0 -9
  309. package/script/plugins/export.d.ts +0 -2
  310. package/script/plugins/export.js +0 -50
  311. package/script/plugins/for.d.ts +0 -2
  312. package/script/plugins/for.js +0 -77
  313. package/script/plugins/function.d.ts +0 -2
  314. package/script/plugins/function.js +0 -40
  315. package/script/plugins/if.d.ts +0 -2
  316. package/script/plugins/if.js +0 -35
  317. package/script/plugins/import.d.ts +0 -2
  318. package/script/plugins/import.js +0 -20
  319. package/script/plugins/include.d.ts +0 -2
  320. package/script/plugins/include.js +0 -26
  321. package/script/plugins/js.d.ts +0 -2
  322. package/script/plugins/js.js +0 -14
  323. package/script/plugins/layout.d.ts +0 -2
  324. package/script/plugins/layout.js +0 -37
  325. package/script/plugins/set.d.ts +0 -2
  326. package/script/plugins/set.js +0 -48
  327. package/script/plugins/unescape.d.ts +0 -2
  328. package/script/plugins/unescape.js +0 -9
  329. package/script/src/environment.d.ts +0 -51
  330. package/script/src/environment.js +0 -208
  331. package/script/src/loader.d.ts +0 -14
  332. package/script/src/loader.js +0 -46
  333. package/script/src/tokenizer.d.ts +0 -13
  334. package/script/src/tokenizer.js +0 -249
  335. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/assert/assert.d.ts +0 -0
  336. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/assert/assertion_error.d.ts +0 -0
  337. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/basename.d.ts +0 -0
  338. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/common.d.ts +0 -0
  339. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/constants.d.ts +0 -0
  340. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/dirname.d.ts +0 -0
  341. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/format.d.ts +0 -0
  342. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/from_file_url.d.ts +0 -0
  343. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/glob_to_reg_exp.d.ts +0 -0
  344. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/normalize.d.ts +0 -0
  345. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/normalize_string.d.ts +0 -0
  346. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/relative.d.ts +0 -0
  347. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/strip_trailing_separators.d.ts +0 -0
  348. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_common/to_file_url.d.ts +0 -0
  349. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_interface.d.ts +0 -0
  350. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/_os.d.ts +0 -0
  351. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/basename.d.ts +0 -0
  352. /package/esm/deps/deno.land/{std@0.210.0/path/posix → std@0.219.1/path}/common.d.ts +0 -0
  353. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/dirname.d.ts +0 -0
  354. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/extname.d.ts +0 -0
  355. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/from_file_url.d.ts +0 -0
  356. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/is_absolute.d.ts +0 -0
  357. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/is_glob.d.ts +0 -0
  358. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/join.d.ts +0 -0
  359. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/normalize.d.ts +0 -0
  360. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/parse.d.ts +0 -0
  361. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/_util.d.ts +0 -0
  362. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/basename.d.ts +0 -0
  363. /package/esm/deps/deno.land/{std@0.210.0/path/windows → std@0.219.1/path/posix}/common.d.ts +0 -0
  364. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/dirname.d.ts +0 -0
  365. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/extname.d.ts +0 -0
  366. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/format.d.ts +0 -0
  367. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/is_absolute.d.ts +0 -0
  368. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/is_glob.d.ts +0 -0
  369. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/join.d.ts +0 -0
  370. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/normalize.d.ts +0 -0
  371. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/relative.d.ts +0 -0
  372. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/resolve.d.ts +0 -0
  373. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/posix/to_namespaced_path.d.ts +0 -0
  374. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/relative.d.ts +0 -0
  375. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/resolve.d.ts +0 -0
  376. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/to_file_url.d.ts +0 -0
  377. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/to_namespaced_path.d.ts +0 -0
  378. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/_util.d.ts +0 -0
  379. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/basename.d.ts +0 -0
  380. /package/{script/deps/deno.land/std@0.210.0/path/posix → esm/deps/deno.land/std@0.219.1/path/windows}/common.d.ts +0 -0
  381. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/dirname.d.ts +0 -0
  382. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/extname.d.ts +0 -0
  383. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/format.d.ts +0 -0
  384. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/is_absolute.d.ts +0 -0
  385. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/is_glob.d.ts +0 -0
  386. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/join.d.ts +0 -0
  387. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/normalize.d.ts +0 -0
  388. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/relative.d.ts +0 -0
  389. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/resolve.d.ts +0 -0
  390. /package/esm/deps/deno.land/{std@0.210.0 → std@0.219.1}/path/windows/to_namespaced_path.d.ts +0 -0
@@ -1,134 +0,0 @@
1
- "use strict";
2
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
3
- // This module is browser compatible.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.normalize = void 0;
6
- const normalize_js_1 = require("../_common/normalize.js");
7
- const constants_js_1 = require("../_common/constants.js");
8
- const normalize_string_js_1 = require("../_common/normalize_string.js");
9
- const _util_js_1 = require("./_util.js");
10
- /**
11
- * Normalize the `path`, resolving `'..'` and `'.'` segments.
12
- * Note that resolving these segments does not necessarily mean that all will be eliminated.
13
- * A `'..'` at the top-level will be preserved, and an empty path is canonically `'.'`.
14
- * @param path to be normalized
15
- */
16
- function normalize(path) {
17
- (0, normalize_js_1.assertArg)(path);
18
- const len = path.length;
19
- let rootEnd = 0;
20
- let device;
21
- let isAbsolute = false;
22
- const code = path.charCodeAt(0);
23
- // Try to match a root
24
- if (len > 1) {
25
- if ((0, _util_js_1.isPathSeparator)(code)) {
26
- // Possible UNC root
27
- // If we started with a separator, we know we at least have an absolute
28
- // path of some kind (UNC or otherwise)
29
- isAbsolute = true;
30
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(1))) {
31
- // Matched double path separator at beginning
32
- let j = 2;
33
- let last = j;
34
- // Match 1 or more non-path separators
35
- for (; j < len; ++j) {
36
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
37
- break;
38
- }
39
- if (j < len && j !== last) {
40
- const firstPart = path.slice(last, j);
41
- // Matched!
42
- last = j;
43
- // Match 1 or more path separators
44
- for (; j < len; ++j) {
45
- if (!(0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
46
- break;
47
- }
48
- if (j < len && j !== last) {
49
- // Matched!
50
- last = j;
51
- // Match 1 or more non-path separators
52
- for (; j < len; ++j) {
53
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
54
- break;
55
- }
56
- if (j === len) {
57
- // We matched a UNC root only
58
- // Return the normalized version of the UNC root since there
59
- // is nothing left to process
60
- return `\\\\${firstPart}\\${path.slice(last)}\\`;
61
- }
62
- else if (j !== last) {
63
- // We matched a UNC root with leftovers
64
- device = `\\\\${firstPart}\\${path.slice(last, j)}`;
65
- rootEnd = j;
66
- }
67
- }
68
- }
69
- }
70
- else {
71
- rootEnd = 1;
72
- }
73
- }
74
- else if ((0, _util_js_1.isWindowsDeviceRoot)(code)) {
75
- // Possible device root
76
- if (path.charCodeAt(1) === constants_js_1.CHAR_COLON) {
77
- device = path.slice(0, 2);
78
- rootEnd = 2;
79
- if (len > 2) {
80
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(2))) {
81
- // Treat separator following drive name as an absolute path
82
- // indicator
83
- isAbsolute = true;
84
- rootEnd = 3;
85
- }
86
- }
87
- }
88
- }
89
- }
90
- else if ((0, _util_js_1.isPathSeparator)(code)) {
91
- // `path` contains just a path separator, exit early to avoid unnecessary
92
- // work
93
- return "\\";
94
- }
95
- let tail;
96
- if (rootEnd < len) {
97
- tail = (0, normalize_string_js_1.normalizeString)(path.slice(rootEnd), !isAbsolute, "\\", _util_js_1.isPathSeparator);
98
- }
99
- else {
100
- tail = "";
101
- }
102
- if (tail.length === 0 && !isAbsolute)
103
- tail = ".";
104
- if (tail.length > 0 && (0, _util_js_1.isPathSeparator)(path.charCodeAt(len - 1))) {
105
- tail += "\\";
106
- }
107
- if (device === undefined) {
108
- if (isAbsolute) {
109
- if (tail.length > 0)
110
- return `\\${tail}`;
111
- else
112
- return "\\";
113
- }
114
- else if (tail.length > 0) {
115
- return tail;
116
- }
117
- else {
118
- return "";
119
- }
120
- }
121
- else if (isAbsolute) {
122
- if (tail.length > 0)
123
- return `${device}\\${tail}`;
124
- else
125
- return `${device}\\`;
126
- }
127
- else if (tail.length > 0) {
128
- return device + tail;
129
- }
130
- else {
131
- return device;
132
- }
133
- }
134
- exports.normalize = normalize;
@@ -1,20 +0,0 @@
1
- "use strict";
2
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
3
- // This module is browser compatible.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.normalizeGlob = void 0;
6
- const normalize_js_1 = require("./normalize.js");
7
- const separator_js_1 = require("./separator.js");
8
- /** Like normalize(), but doesn't collapse "**\/.." when `globstar` is true. */
9
- function normalizeGlob(glob, { globstar = false } = {}) {
10
- if (glob.match(/\0/g)) {
11
- throw new Error(`Glob contains invalid characters: "${glob}"`);
12
- }
13
- if (!globstar) {
14
- return (0, normalize_js_1.normalize)(glob);
15
- }
16
- const s = separator_js_1.SEP_PATTERN.source;
17
- const badParentPattern = new RegExp(`(?<=(${s}|^)\\*\\*${s})\\.\\.(?=${s}|$)`, "g");
18
- return (0, normalize_js_1.normalize)(glob.replace(badParentPattern, "\0")).replace(/\0/g, "..");
19
- }
20
- exports.normalizeGlob = normalizeGlob;
@@ -1,6 +0,0 @@
1
- import { ParsedPath } from "../_interface.js";
2
- /**
3
- * Return a `ParsedPath` object of the `path`.
4
- * @param path to process
5
- */
6
- export declare function parse(path: string): ParsedPath;
@@ -1,163 +0,0 @@
1
- "use strict";
2
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
3
- // This module is browser compatible.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.parse = void 0;
6
- const constants_js_1 = require("../_common/constants.js");
7
- const assert_path_js_1 = require("../_common/assert_path.js");
8
- const _util_js_1 = require("./_util.js");
9
- /**
10
- * Return a `ParsedPath` object of the `path`.
11
- * @param path to process
12
- */
13
- function parse(path) {
14
- (0, assert_path_js_1.assertPath)(path);
15
- const ret = { root: "", dir: "", base: "", ext: "", name: "" };
16
- const len = path.length;
17
- if (len === 0)
18
- return ret;
19
- let rootEnd = 0;
20
- let code = path.charCodeAt(0);
21
- // Try to match a root
22
- if (len > 1) {
23
- if ((0, _util_js_1.isPathSeparator)(code)) {
24
- // Possible UNC root
25
- rootEnd = 1;
26
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(1))) {
27
- // Matched double path separator at beginning
28
- let j = 2;
29
- let last = j;
30
- // Match 1 or more non-path separators
31
- for (; j < len; ++j) {
32
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
33
- break;
34
- }
35
- if (j < len && j !== last) {
36
- // Matched!
37
- last = j;
38
- // Match 1 or more path separators
39
- for (; j < len; ++j) {
40
- if (!(0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
41
- break;
42
- }
43
- if (j < len && j !== last) {
44
- // Matched!
45
- last = j;
46
- // Match 1 or more non-path separators
47
- for (; j < len; ++j) {
48
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
49
- break;
50
- }
51
- if (j === len) {
52
- // We matched a UNC root only
53
- rootEnd = j;
54
- }
55
- else if (j !== last) {
56
- // We matched a UNC root with leftovers
57
- rootEnd = j + 1;
58
- }
59
- }
60
- }
61
- }
62
- }
63
- else if ((0, _util_js_1.isWindowsDeviceRoot)(code)) {
64
- // Possible device root
65
- if (path.charCodeAt(1) === constants_js_1.CHAR_COLON) {
66
- rootEnd = 2;
67
- if (len > 2) {
68
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(2))) {
69
- if (len === 3) {
70
- // `path` contains just a drive root, exit early to avoid
71
- // unnecessary work
72
- ret.root = ret.dir = path;
73
- ret.base = "\\";
74
- return ret;
75
- }
76
- rootEnd = 3;
77
- }
78
- }
79
- else {
80
- // `path` contains just a relative drive root, exit early to avoid
81
- // unnecessary work
82
- ret.root = ret.dir = path;
83
- return ret;
84
- }
85
- }
86
- }
87
- }
88
- else if ((0, _util_js_1.isPathSeparator)(code)) {
89
- // `path` contains just a path separator, exit early to avoid
90
- // unnecessary work
91
- ret.root = ret.dir = path;
92
- ret.base = "\\";
93
- return ret;
94
- }
95
- if (rootEnd > 0)
96
- ret.root = path.slice(0, rootEnd);
97
- let startDot = -1;
98
- let startPart = rootEnd;
99
- let end = -1;
100
- let matchedSlash = true;
101
- let i = path.length - 1;
102
- // Track the state of characters (if any) we see before our first dot and
103
- // after any path separator we find
104
- let preDotState = 0;
105
- // Get non-dir info
106
- for (; i >= rootEnd; --i) {
107
- code = path.charCodeAt(i);
108
- if ((0, _util_js_1.isPathSeparator)(code)) {
109
- // If we reached a path separator that was not part of a set of path
110
- // separators at the end of the string, stop now
111
- if (!matchedSlash) {
112
- startPart = i + 1;
113
- break;
114
- }
115
- continue;
116
- }
117
- if (end === -1) {
118
- // We saw the first non-path separator, mark this as the end of our
119
- // extension
120
- matchedSlash = false;
121
- end = i + 1;
122
- }
123
- if (code === constants_js_1.CHAR_DOT) {
124
- // If this is our first dot, mark it as the start of our extension
125
- if (startDot === -1)
126
- startDot = i;
127
- else if (preDotState !== 1)
128
- preDotState = 1;
129
- }
130
- else if (startDot !== -1) {
131
- // We saw a non-dot and non-path separator before our dot, so we should
132
- // have a good chance at having a non-empty extension
133
- preDotState = -1;
134
- }
135
- }
136
- if (startDot === -1 ||
137
- end === -1 ||
138
- // We saw a non-dot character immediately before the dot
139
- preDotState === 0 ||
140
- // The (right-most) trimmed path component is exactly '..'
141
- (preDotState === 1 && startDot === end - 1 && startDot === startPart + 1)) {
142
- if (end !== -1) {
143
- ret.base = ret.name = path.slice(startPart, end);
144
- }
145
- }
146
- else {
147
- ret.name = path.slice(startPart, startDot);
148
- ret.base = path.slice(startPart, end);
149
- ret.ext = path.slice(startDot, end);
150
- }
151
- // Fallback to '\' in case there is no basename
152
- ret.base = ret.base || "\\";
153
- // If the directory is the root, use the entire root as the `dir` including
154
- // the trailing slash if any (`C:\abc` -> `C:\`). Otherwise, strip out the
155
- // trailing slash (`C:\abc\def` -> `C:\abc`).
156
- if (startPart > 0 && startPart !== rootEnd) {
157
- ret.dir = path.slice(0, startPart - 1);
158
- }
159
- else
160
- ret.dir = ret.root;
161
- return ret;
162
- }
163
- exports.parse = parse;
@@ -1,12 +0,0 @@
1
- /**
2
- * Return the relative path from `from` to `to` based on current working directory.
3
- *
4
- * An example in windws, for instance:
5
- * from = 'C:\\orandea\\test\\aaa'
6
- * to = 'C:\\orandea\\impl\\bbb'
7
- * The output of the function should be: '..\\..\\impl\\bbb'
8
- *
9
- * @param from path in current working directory
10
- * @param to path in current working directory
11
- */
12
- export declare function relative(from: string, to: string): string;
@@ -1,125 +0,0 @@
1
- "use strict";
2
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
3
- // This module is browser compatible.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.relative = void 0;
6
- const constants_js_1 = require("../_common/constants.js");
7
- const resolve_js_1 = require("./resolve.js");
8
- const relative_js_1 = require("../_common/relative.js");
9
- /**
10
- * Return the relative path from `from` to `to` based on current working directory.
11
- *
12
- * An example in windws, for instance:
13
- * from = 'C:\\orandea\\test\\aaa'
14
- * to = 'C:\\orandea\\impl\\bbb'
15
- * The output of the function should be: '..\\..\\impl\\bbb'
16
- *
17
- * @param from path in current working directory
18
- * @param to path in current working directory
19
- */
20
- function relative(from, to) {
21
- (0, relative_js_1.assertArgs)(from, to);
22
- const fromOrig = (0, resolve_js_1.resolve)(from);
23
- const toOrig = (0, resolve_js_1.resolve)(to);
24
- if (fromOrig === toOrig)
25
- return "";
26
- from = fromOrig.toLowerCase();
27
- to = toOrig.toLowerCase();
28
- if (from === to)
29
- return "";
30
- // Trim any leading backslashes
31
- let fromStart = 0;
32
- let fromEnd = from.length;
33
- for (; fromStart < fromEnd; ++fromStart) {
34
- if (from.charCodeAt(fromStart) !== constants_js_1.CHAR_BACKWARD_SLASH)
35
- break;
36
- }
37
- // Trim trailing backslashes (applicable to UNC paths only)
38
- for (; fromEnd - 1 > fromStart; --fromEnd) {
39
- if (from.charCodeAt(fromEnd - 1) !== constants_js_1.CHAR_BACKWARD_SLASH)
40
- break;
41
- }
42
- const fromLen = fromEnd - fromStart;
43
- // Trim any leading backslashes
44
- let toStart = 0;
45
- let toEnd = to.length;
46
- for (; toStart < toEnd; ++toStart) {
47
- if (to.charCodeAt(toStart) !== constants_js_1.CHAR_BACKWARD_SLASH)
48
- break;
49
- }
50
- // Trim trailing backslashes (applicable to UNC paths only)
51
- for (; toEnd - 1 > toStart; --toEnd) {
52
- if (to.charCodeAt(toEnd - 1) !== constants_js_1.CHAR_BACKWARD_SLASH)
53
- break;
54
- }
55
- const toLen = toEnd - toStart;
56
- // Compare paths to find the longest common path from root
57
- const length = fromLen < toLen ? fromLen : toLen;
58
- let lastCommonSep = -1;
59
- let i = 0;
60
- for (; i <= length; ++i) {
61
- if (i === length) {
62
- if (toLen > length) {
63
- if (to.charCodeAt(toStart + i) === constants_js_1.CHAR_BACKWARD_SLASH) {
64
- // We get here if `from` is the exact base path for `to`.
65
- // For example: from='C:\\foo\\bar'; to='C:\\foo\\bar\\baz'
66
- return toOrig.slice(toStart + i + 1);
67
- }
68
- else if (i === 2) {
69
- // We get here if `from` is the device root.
70
- // For example: from='C:\\'; to='C:\\foo'
71
- return toOrig.slice(toStart + i);
72
- }
73
- }
74
- if (fromLen > length) {
75
- if (from.charCodeAt(fromStart + i) === constants_js_1.CHAR_BACKWARD_SLASH) {
76
- // We get here if `to` is the exact base path for `from`.
77
- // For example: from='C:\\foo\\bar'; to='C:\\foo'
78
- lastCommonSep = i;
79
- }
80
- else if (i === 2) {
81
- // We get here if `to` is the device root.
82
- // For example: from='C:\\foo\\bar'; to='C:\\'
83
- lastCommonSep = 3;
84
- }
85
- }
86
- break;
87
- }
88
- const fromCode = from.charCodeAt(fromStart + i);
89
- const toCode = to.charCodeAt(toStart + i);
90
- if (fromCode !== toCode)
91
- break;
92
- else if (fromCode === constants_js_1.CHAR_BACKWARD_SLASH)
93
- lastCommonSep = i;
94
- }
95
- // We found a mismatch before the first common path separator was seen, so
96
- // return the original `to`.
97
- if (i !== length && lastCommonSep === -1) {
98
- return toOrig;
99
- }
100
- let out = "";
101
- if (lastCommonSep === -1)
102
- lastCommonSep = 0;
103
- // Generate the relative path based on the path difference between `to` and
104
- // `from`
105
- for (i = fromStart + lastCommonSep + 1; i <= fromEnd; ++i) {
106
- if (i === fromEnd || from.charCodeAt(i) === constants_js_1.CHAR_BACKWARD_SLASH) {
107
- if (out.length === 0)
108
- out += "..";
109
- else
110
- out += "\\..";
111
- }
112
- }
113
- // Lastly, append the rest of the destination (`to`) path that comes after
114
- // the common path parts
115
- if (out.length > 0) {
116
- return out + toOrig.slice(toStart + lastCommonSep, toEnd);
117
- }
118
- else {
119
- toStart += lastCommonSep;
120
- if (toOrig.charCodeAt(toStart) === constants_js_1.CHAR_BACKWARD_SLASH)
121
- ++toStart;
122
- return toOrig.slice(toStart, toEnd);
123
- }
124
- }
125
- exports.relative = relative;
@@ -1,5 +0,0 @@
1
- /**
2
- * Resolves path segments into a `path`
3
- * @param pathSegments to process to path
4
- */
5
- export declare function resolve(...pathSegments: string[]): string;
@@ -1,170 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
- Object.defineProperty(o, "default", { enumerable: true, value: v });
15
- }) : function(o, v) {
16
- o["default"] = v;
17
- });
18
- var __importStar = (this && this.__importStar) || function (mod) {
19
- if (mod && mod.__esModule) return mod;
20
- var result = {};
21
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
- __setModuleDefault(result, mod);
23
- return result;
24
- };
25
- Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.resolve = void 0;
27
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
28
- // This module is browser compatible.
29
- const dntShim = __importStar(require("../../../../../_dnt.shims.js"));
30
- const constants_js_1 = require("../_common/constants.js");
31
- const normalize_string_js_1 = require("../_common/normalize_string.js");
32
- const assert_path_js_1 = require("../_common/assert_path.js");
33
- const _util_js_1 = require("./_util.js");
34
- /**
35
- * Resolves path segments into a `path`
36
- * @param pathSegments to process to path
37
- */
38
- function resolve(...pathSegments) {
39
- let resolvedDevice = "";
40
- let resolvedTail = "";
41
- let resolvedAbsolute = false;
42
- for (let i = pathSegments.length - 1; i >= -1; i--) {
43
- let path;
44
- // deno-lint-ignore no-explicit-any
45
- const { Deno } = dntShim.dntGlobalThis;
46
- if (i >= 0) {
47
- path = pathSegments[i];
48
- }
49
- else if (!resolvedDevice) {
50
- if (typeof Deno?.cwd !== "function") {
51
- throw new TypeError("Resolved a drive-letter-less path without a CWD.");
52
- }
53
- path = Deno.cwd();
54
- }
55
- else {
56
- if (typeof Deno?.env?.get !== "function" || typeof Deno?.cwd !== "function") {
57
- throw new TypeError("Resolved a relative path without a CWD.");
58
- }
59
- path = Deno.cwd();
60
- // Verify that a cwd was found and that it actually points
61
- // to our drive. If not, default to the drive's root.
62
- if (path === undefined ||
63
- path.slice(0, 3).toLowerCase() !== `${resolvedDevice.toLowerCase()}\\`) {
64
- path = `${resolvedDevice}\\`;
65
- }
66
- }
67
- (0, assert_path_js_1.assertPath)(path);
68
- const len = path.length;
69
- // Skip empty entries
70
- if (len === 0)
71
- continue;
72
- let rootEnd = 0;
73
- let device = "";
74
- let isAbsolute = false;
75
- const code = path.charCodeAt(0);
76
- // Try to match a root
77
- if (len > 1) {
78
- if ((0, _util_js_1.isPathSeparator)(code)) {
79
- // Possible UNC root
80
- // If we started with a separator, we know we at least have an
81
- // absolute path of some kind (UNC or otherwise)
82
- isAbsolute = true;
83
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(1))) {
84
- // Matched double path separator at beginning
85
- let j = 2;
86
- let last = j;
87
- // Match 1 or more non-path separators
88
- for (; j < len; ++j) {
89
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
90
- break;
91
- }
92
- if (j < len && j !== last) {
93
- const firstPart = path.slice(last, j);
94
- // Matched!
95
- last = j;
96
- // Match 1 or more path separators
97
- for (; j < len; ++j) {
98
- if (!(0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
99
- break;
100
- }
101
- if (j < len && j !== last) {
102
- // Matched!
103
- last = j;
104
- // Match 1 or more non-path separators
105
- for (; j < len; ++j) {
106
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(j)))
107
- break;
108
- }
109
- if (j === len) {
110
- // We matched a UNC root only
111
- device = `\\\\${firstPart}\\${path.slice(last)}`;
112
- rootEnd = j;
113
- }
114
- else if (j !== last) {
115
- // We matched a UNC root with leftovers
116
- device = `\\\\${firstPart}\\${path.slice(last, j)}`;
117
- rootEnd = j;
118
- }
119
- }
120
- }
121
- }
122
- else {
123
- rootEnd = 1;
124
- }
125
- }
126
- else if ((0, _util_js_1.isWindowsDeviceRoot)(code)) {
127
- // Possible device root
128
- if (path.charCodeAt(1) === constants_js_1.CHAR_COLON) {
129
- device = path.slice(0, 2);
130
- rootEnd = 2;
131
- if (len > 2) {
132
- if ((0, _util_js_1.isPathSeparator)(path.charCodeAt(2))) {
133
- // Treat separator following drive name as an absolute path
134
- // indicator
135
- isAbsolute = true;
136
- rootEnd = 3;
137
- }
138
- }
139
- }
140
- }
141
- }
142
- else if ((0, _util_js_1.isPathSeparator)(code)) {
143
- // `path` contains just a path separator
144
- rootEnd = 1;
145
- isAbsolute = true;
146
- }
147
- if (device.length > 0 &&
148
- resolvedDevice.length > 0 &&
149
- device.toLowerCase() !== resolvedDevice.toLowerCase()) {
150
- // This path points to another device so it is not applicable
151
- continue;
152
- }
153
- if (resolvedDevice.length === 0 && device.length > 0) {
154
- resolvedDevice = device;
155
- }
156
- if (!resolvedAbsolute) {
157
- resolvedTail = `${path.slice(rootEnd)}\\${resolvedTail}`;
158
- resolvedAbsolute = isAbsolute;
159
- }
160
- if (resolvedAbsolute && resolvedDevice.length > 0)
161
- break;
162
- }
163
- // At this point the path should be resolved to a full absolute path,
164
- // but handle relative paths to be safe (might happen when Deno.cwd()
165
- // fails)
166
- // Normalize the tail path
167
- resolvedTail = (0, normalize_string_js_1.normalizeString)(resolvedTail, !resolvedAbsolute, "\\", _util_js_1.isPathSeparator);
168
- return resolvedDevice + (resolvedAbsolute ? "\\" : "") + resolvedTail || ".";
169
- }
170
- exports.resolve = resolve;
@@ -1,2 +0,0 @@
1
- export declare const SEP = "\\";
2
- export declare const SEP_PATTERN: RegExp;
@@ -1,7 +0,0 @@
1
- "use strict";
2
- // Copyright 2018-2023 the Deno authors. All rights reserved. MIT license.
3
- // This module is browser compatible.
4
- Object.defineProperty(exports, "__esModule", { value: true });
5
- exports.SEP_PATTERN = exports.SEP = void 0;
6
- exports.SEP = "\\";
7
- exports.SEP_PATTERN = /[\\/]+/;