@powerlines/core 0.15.0 → 0.15.2

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 (401) hide show
  1. package/dist/constants/api.cjs +6 -5
  2. package/dist/constants/api.d.cts +3 -3
  3. package/dist/constants/api.d.cts.map +1 -1
  4. package/dist/constants/api.d.mts +3 -3
  5. package/dist/constants/api.d.mts.map +1 -1
  6. package/dist/constants/api.mjs +4 -4
  7. package/dist/constants/api.mjs.map +1 -1
  8. package/dist/constants/commands.cjs +3 -2
  9. package/dist/constants/commands.d.cts +1 -1
  10. package/dist/constants/commands.d.mts +1 -1
  11. package/dist/constants/commands.mjs +2 -2
  12. package/dist/constants/commands.mjs.map +1 -1
  13. package/dist/constants/devtools.cjs +23 -0
  14. package/dist/constants/devtools.d.cts +13 -0
  15. package/dist/constants/devtools.d.cts.map +1 -0
  16. package/dist/constants/devtools.d.mts +13 -0
  17. package/dist/constants/devtools.d.mts.map +1 -0
  18. package/dist/constants/devtools.mjs +14 -0
  19. package/dist/constants/devtools.mjs.map +1 -0
  20. package/dist/constants/environments.cjs +1 -0
  21. package/dist/constants/extensions.cjs +21 -0
  22. package/dist/constants/extensions.d.cts +5 -0
  23. package/dist/constants/extensions.d.cts.map +1 -0
  24. package/dist/constants/extensions.d.mts +5 -0
  25. package/dist/constants/extensions.d.mts.map +1 -0
  26. package/dist/constants/extensions.mjs +20 -0
  27. package/dist/constants/extensions.mjs.map +1 -0
  28. package/dist/constants/fs.cjs +1 -0
  29. package/dist/constants/hooks.cjs +1 -0
  30. package/dist/constants/index.cjs +48 -30
  31. package/dist/constants/index.d.cts +5 -3
  32. package/dist/constants/index.d.mts +5 -3
  33. package/dist/constants/index.mjs +5 -3
  34. package/dist/constants/log-level.cjs +90 -0
  35. package/dist/constants/log-level.d.cts +63 -0
  36. package/dist/constants/log-level.d.cts.map +1 -0
  37. package/dist/constants/log-level.d.mts +63 -0
  38. package/dist/constants/log-level.d.mts.map +1 -0
  39. package/dist/constants/log-level.mjs +82 -0
  40. package/dist/constants/log-level.mjs.map +1 -0
  41. package/dist/constants/meta.cjs +1 -0
  42. package/dist/constants/plugin.cjs +3 -2
  43. package/dist/constants/plugin.d.cts +2 -2
  44. package/dist/constants/plugin.d.mts +2 -2
  45. package/dist/context/base-context.cjs +127 -0
  46. package/dist/context/base-context.d.cts +81 -0
  47. package/dist/context/base-context.d.cts.map +1 -0
  48. package/dist/context/base-context.d.mts +81 -0
  49. package/dist/context/base-context.d.mts.map +1 -0
  50. package/dist/context/base-context.mjs +125 -0
  51. package/dist/context/base-context.mjs.map +1 -0
  52. package/dist/context/context.cjs +934 -0
  53. package/dist/context/context.d.cts +369 -0
  54. package/dist/context/context.d.cts.map +1 -0
  55. package/dist/context/context.d.mts +369 -0
  56. package/dist/context/context.d.mts.map +1 -0
  57. package/dist/context/context.mjs +932 -0
  58. package/dist/context/context.mjs.map +1 -0
  59. package/dist/context/environment-context.cjs +219 -0
  60. package/dist/context/environment-context.d.cts +100 -0
  61. package/dist/context/environment-context.d.cts.map +1 -0
  62. package/dist/context/environment-context.d.mts +100 -0
  63. package/dist/context/environment-context.d.mts.map +1 -0
  64. package/dist/context/environment-context.mjs +218 -0
  65. package/dist/context/environment-context.mjs.map +1 -0
  66. package/dist/context/execution-context.cjs +230 -0
  67. package/dist/context/execution-context.d.cts +101 -0
  68. package/dist/context/execution-context.d.cts.map +1 -0
  69. package/dist/context/execution-context.d.mts +101 -0
  70. package/dist/context/execution-context.d.mts.map +1 -0
  71. package/dist/context/execution-context.mjs +228 -0
  72. package/dist/context/execution-context.mjs.map +1 -0
  73. package/dist/context/index.cjs +12 -0
  74. package/dist/context/index.d.cts +6 -0
  75. package/dist/context/index.d.mts +6 -0
  76. package/dist/context/index.mjs +7 -0
  77. package/dist/context/plugin-context.cjs +83 -0
  78. package/dist/context/plugin-context.d.cts +18 -0
  79. package/dist/context/plugin-context.d.cts.map +1 -0
  80. package/dist/context/plugin-context.d.mts +18 -0
  81. package/dist/context/plugin-context.d.mts.map +1 -0
  82. package/dist/context/plugin-context.mjs +82 -0
  83. package/dist/context/plugin-context.mjs.map +1 -0
  84. package/dist/index.cjs +62 -9
  85. package/dist/index.d.cts +20 -9
  86. package/dist/index.d.mts +20 -9
  87. package/dist/index.mjs +17 -5
  88. package/dist/lib/config.cjs +160 -15
  89. package/dist/lib/config.d.cts +92 -6
  90. package/dist/lib/config.d.cts.map +1 -1
  91. package/dist/lib/config.d.mts +92 -6
  92. package/dist/lib/config.d.mts.map +1 -1
  93. package/dist/lib/config.mjs +154 -16
  94. package/dist/lib/config.mjs.map +1 -1
  95. package/dist/lib/context-helpers.cjs +43 -0
  96. package/dist/lib/context-helpers.d.cts +19 -0
  97. package/dist/lib/context-helpers.d.cts.map +1 -0
  98. package/dist/lib/context-helpers.d.mts +19 -0
  99. package/dist/lib/context-helpers.d.mts.map +1 -0
  100. package/dist/lib/context-helpers.mjs +41 -0
  101. package/dist/lib/context-helpers.mjs.map +1 -0
  102. package/dist/lib/entry.cjs +5 -5
  103. package/dist/lib/entry.d.cts +5 -5
  104. package/dist/lib/entry.d.cts.map +1 -1
  105. package/dist/lib/entry.d.mts +5 -5
  106. package/dist/lib/entry.d.mts.map +1 -1
  107. package/dist/lib/entry.mjs +5 -5
  108. package/dist/lib/entry.mjs.map +1 -1
  109. package/dist/lib/environment.cjs +72 -0
  110. package/dist/lib/environment.d.cts +12 -0
  111. package/dist/lib/environment.d.cts.map +1 -0
  112. package/dist/lib/environment.d.mts +12 -0
  113. package/dist/lib/environment.d.mts.map +1 -0
  114. package/dist/lib/environment.mjs +67 -0
  115. package/dist/lib/environment.mjs.map +1 -0
  116. package/dist/lib/events.cjs +43 -0
  117. package/dist/lib/events.d.cts +10 -0
  118. package/dist/lib/events.d.cts.map +1 -0
  119. package/dist/lib/events.d.mts +10 -0
  120. package/dist/lib/events.d.mts.map +1 -0
  121. package/dist/lib/events.mjs +42 -0
  122. package/dist/lib/events.mjs.map +1 -0
  123. package/dist/lib/generate-types.cjs +371 -0
  124. package/dist/lib/generate-types.d.cts +67 -0
  125. package/dist/lib/generate-types.d.cts.map +1 -0
  126. package/dist/lib/generate-types.d.mts +67 -0
  127. package/dist/lib/generate-types.d.mts.map +1 -0
  128. package/dist/lib/generate-types.mjs +368 -0
  129. package/dist/lib/generate-types.mjs.map +1 -0
  130. package/dist/lib/hooks.cjs +152 -0
  131. package/dist/lib/hooks.d.cts +28 -0
  132. package/dist/lib/hooks.d.cts.map +1 -0
  133. package/dist/lib/hooks.d.mts +28 -0
  134. package/dist/lib/hooks.d.mts.map +1 -0
  135. package/dist/lib/hooks.mjs +147 -0
  136. package/dist/lib/hooks.mjs.map +1 -0
  137. package/dist/lib/index.cjs +64 -9
  138. package/dist/lib/index.d.cts +15 -3
  139. package/dist/lib/index.d.mts +15 -3
  140. package/dist/lib/index.mjs +19 -5
  141. package/dist/lib/install-dependencies.cjs +25 -0
  142. package/dist/lib/install-dependencies.d.cts +12 -0
  143. package/dist/lib/install-dependencies.d.cts.map +1 -0
  144. package/dist/lib/install-dependencies.d.mts +12 -0
  145. package/dist/lib/install-dependencies.d.mts.map +1 -0
  146. package/dist/lib/install-dependencies.mjs +24 -0
  147. package/dist/lib/install-dependencies.mjs.map +1 -0
  148. package/dist/lib/meta.cjs +57 -0
  149. package/dist/lib/meta.d.cts +34 -0
  150. package/dist/lib/meta.d.cts.map +1 -0
  151. package/dist/lib/meta.d.mts +34 -0
  152. package/dist/lib/meta.d.mts.map +1 -0
  153. package/dist/lib/meta.mjs +54 -0
  154. package/dist/lib/meta.mjs.map +1 -0
  155. package/dist/lib/plugins.cjs +150 -0
  156. package/dist/lib/plugins.d.cts +40 -0
  157. package/dist/lib/plugins.d.cts.map +1 -0
  158. package/dist/lib/plugins.d.mts +40 -0
  159. package/dist/lib/plugins.d.mts.map +1 -0
  160. package/dist/lib/plugins.mjs +146 -0
  161. package/dist/lib/plugins.mjs.map +1 -0
  162. package/dist/lib/resolver.cjs +35 -0
  163. package/dist/lib/resolver.d.cts +21 -0
  164. package/dist/lib/resolver.d.cts.map +1 -0
  165. package/dist/lib/resolver.d.mts +21 -0
  166. package/dist/lib/resolver.d.mts.map +1 -0
  167. package/dist/lib/resolver.mjs +33 -0
  168. package/dist/lib/resolver.mjs.map +1 -0
  169. package/dist/lib/schemas.cjs +9 -0
  170. package/dist/lib/schemas.d.cts +2 -0
  171. package/dist/lib/schemas.d.mts +2 -0
  172. package/dist/lib/schemas.mjs +3 -0
  173. package/dist/lib/streaming-channel.cjs +260 -0
  174. package/dist/lib/streaming-channel.d.cts +133 -0
  175. package/dist/lib/streaming-channel.d.cts.map +1 -0
  176. package/dist/lib/streaming-channel.d.mts +133 -0
  177. package/dist/lib/streaming-channel.d.mts.map +1 -0
  178. package/dist/lib/streaming-channel.mjs +258 -0
  179. package/dist/lib/streaming-channel.mjs.map +1 -0
  180. package/dist/lib/typescript/index.cjs +16 -0
  181. package/dist/lib/typescript/index.d.cts +3 -0
  182. package/dist/lib/typescript/index.d.mts +3 -0
  183. package/dist/lib/typescript/index.mjs +4 -0
  184. package/dist/lib/typescript/ts-morph.cjs +105 -0
  185. package/dist/lib/typescript/ts-morph.d.cts +38 -0
  186. package/dist/lib/typescript/ts-morph.d.cts.map +1 -0
  187. package/dist/lib/typescript/ts-morph.d.mts +38 -0
  188. package/dist/lib/typescript/ts-morph.d.mts.map +1 -0
  189. package/dist/lib/typescript/ts-morph.mjs +102 -0
  190. package/dist/lib/typescript/ts-morph.mjs.map +1 -0
  191. package/dist/lib/typescript/tsconfig.cjs +253 -0
  192. package/dist/lib/typescript/tsconfig.d.cts +77 -0
  193. package/dist/lib/typescript/tsconfig.d.cts.map +1 -0
  194. package/dist/lib/typescript/tsconfig.d.mts +77 -0
  195. package/dist/lib/typescript/tsconfig.d.mts.map +1 -0
  196. package/dist/lib/typescript/tsconfig.mjs +240 -0
  197. package/dist/lib/typescript/tsconfig.mjs.map +1 -0
  198. package/dist/lib/unplugin/helpers.cjs +2 -2
  199. package/dist/lib/unplugin/module-resolution.cjs +18 -18
  200. package/dist/lib/unplugin/module-resolution.d.cts +2 -2
  201. package/dist/lib/unplugin/module-resolution.d.cts.map +1 -1
  202. package/dist/lib/unplugin/module-resolution.d.mts +2 -2
  203. package/dist/lib/unplugin/module-resolution.d.mts.map +1 -1
  204. package/dist/lib/unplugin/module-resolution.mjs +18 -18
  205. package/dist/lib/unplugin/module-resolution.mjs.map +1 -1
  206. package/dist/lib/unplugin/plugin.cjs +55 -62
  207. package/dist/lib/unplugin/plugin.d.cts +11 -12
  208. package/dist/lib/unplugin/plugin.d.cts.map +1 -1
  209. package/dist/lib/unplugin/plugin.d.mts +11 -12
  210. package/dist/lib/unplugin/plugin.d.mts.map +1 -1
  211. package/dist/lib/unplugin/plugin.mjs +55 -62
  212. package/dist/lib/unplugin/plugin.mjs.map +1 -1
  213. package/dist/lib/utilities/file-header.cjs +2 -2
  214. package/dist/lib/utilities/file-header.mjs +2 -2
  215. package/dist/lib/utilities/file-header.mjs.map +1 -1
  216. package/dist/lib/utilities/format.cjs +1 -1
  217. package/dist/lib/utilities/format.mjs +1 -1
  218. package/dist/lib/utilities/index.cjs +2 -2
  219. package/dist/lib/utilities/index.mjs +2 -2
  220. package/dist/lib/utilities/write-file.cjs +1 -2
  221. package/dist/lib/utilities/write-file.d.cts +1 -1
  222. package/dist/lib/utilities/write-file.d.cts.map +1 -1
  223. package/dist/lib/utilities/write-file.d.mts +1 -1
  224. package/dist/lib/utilities/write-file.d.mts.map +1 -1
  225. package/dist/lib/utilities/write-file.mjs +1 -2
  226. package/dist/lib/utilities/write-file.mjs.map +1 -1
  227. package/dist/lib/vfs.cjs +1104 -0
  228. package/dist/lib/vfs.d.cts +321 -0
  229. package/dist/lib/vfs.d.cts.map +1 -0
  230. package/dist/lib/vfs.d.mts +321 -0
  231. package/dist/lib/vfs.d.mts.map +1 -0
  232. package/dist/lib/vfs.mjs +1102 -0
  233. package/dist/lib/vfs.mjs.map +1 -0
  234. package/dist/plugin-base.cjs +1 -1
  235. package/dist/plugin-base.mjs +1 -1
  236. package/dist/plugin-base.mjs.map +1 -1
  237. package/dist/plugin-utils/build-helpers.cjs +2 -2
  238. package/dist/plugin-utils/build-helpers.d.cts +2 -2
  239. package/dist/plugin-utils/build-helpers.d.cts.map +1 -1
  240. package/dist/plugin-utils/build-helpers.d.mts +2 -2
  241. package/dist/plugin-utils/build-helpers.d.mts.map +1 -1
  242. package/dist/plugin-utils/build-helpers.mjs +2 -2
  243. package/dist/plugin-utils/build-helpers.mjs.map +1 -1
  244. package/dist/plugin-utils/context-helpers.cjs +22 -12
  245. package/dist/plugin-utils/context-helpers.d.cts +9 -1
  246. package/dist/plugin-utils/context-helpers.d.cts.map +1 -1
  247. package/dist/plugin-utils/context-helpers.d.mts +9 -1
  248. package/dist/plugin-utils/context-helpers.d.mts.map +1 -1
  249. package/dist/plugin-utils/context-helpers.mjs +22 -13
  250. package/dist/plugin-utils/context-helpers.mjs.map +1 -1
  251. package/dist/plugin-utils/filter.cjs +13 -5
  252. package/dist/plugin-utils/filter.d.cts +2 -1
  253. package/dist/plugin-utils/filter.d.cts.map +1 -1
  254. package/dist/plugin-utils/filter.d.mts +2 -1
  255. package/dist/plugin-utils/filter.d.mts.map +1 -1
  256. package/dist/plugin-utils/filter.mjs +13 -6
  257. package/dist/plugin-utils/filter.mjs.map +1 -1
  258. package/dist/plugin-utils/format.cjs +44 -0
  259. package/dist/plugin-utils/format.d.cts +11 -0
  260. package/dist/plugin-utils/format.d.cts.map +1 -0
  261. package/dist/plugin-utils/format.d.mts +11 -0
  262. package/dist/plugin-utils/format.d.mts.map +1 -0
  263. package/dist/plugin-utils/format.mjs +43 -0
  264. package/dist/plugin-utils/format.mjs.map +1 -0
  265. package/dist/plugin-utils/helpers.cjs +6 -6
  266. package/dist/plugin-utils/helpers.d.cts +15 -15
  267. package/dist/plugin-utils/helpers.d.cts.map +1 -1
  268. package/dist/plugin-utils/helpers.d.mts +15 -15
  269. package/dist/plugin-utils/helpers.d.mts.map +1 -1
  270. package/dist/plugin-utils/helpers.mjs +1 -1
  271. package/dist/plugin-utils/helpers.mjs.map +1 -1
  272. package/dist/plugin-utils/index.cjs +34 -4
  273. package/dist/plugin-utils/index.d.cts +7 -4
  274. package/dist/plugin-utils/index.d.mts +7 -4
  275. package/dist/plugin-utils/index.mjs +9 -6
  276. package/dist/plugin-utils/install.cjs +47 -0
  277. package/dist/plugin-utils/install.d.cts +23 -0
  278. package/dist/plugin-utils/install.d.cts.map +1 -0
  279. package/dist/plugin-utils/install.d.mts +23 -0
  280. package/dist/plugin-utils/install.d.mts.map +1 -0
  281. package/dist/plugin-utils/install.mjs +45 -0
  282. package/dist/plugin-utils/install.mjs.map +1 -0
  283. package/dist/plugin-utils/logging.cjs +588 -1
  284. package/dist/plugin-utils/logging.d.cts +93 -1
  285. package/dist/plugin-utils/logging.d.cts.map +1 -1
  286. package/dist/plugin-utils/logging.d.mts +93 -1
  287. package/dist/plugin-utils/logging.d.mts.map +1 -1
  288. package/dist/plugin-utils/logging.mjs +572 -1
  289. package/dist/plugin-utils/logging.mjs.map +1 -1
  290. package/dist/plugin-utils/merge.cjs +1 -1
  291. package/dist/plugin-utils/merge.mjs +1 -1
  292. package/dist/plugin-utils/modules.cjs +1 -1
  293. package/dist/plugin-utils/modules.mjs +1 -1
  294. package/dist/plugin-utils/modules.mjs.map +1 -1
  295. package/dist/plugin-utils/paths.cjs +6 -2
  296. package/dist/plugin-utils/paths.mjs +6 -2
  297. package/dist/plugin-utils/paths.mjs.map +1 -1
  298. package/dist/plugin-utils/virtual.cjs +80 -0
  299. package/dist/plugin-utils/virtual.d.cts +69 -0
  300. package/dist/plugin-utils/virtual.d.cts.map +1 -0
  301. package/dist/plugin-utils/virtual.d.mts +69 -0
  302. package/dist/plugin-utils/virtual.d.mts.map +1 -0
  303. package/dist/plugin-utils/virtual.mjs +73 -0
  304. package/dist/plugin-utils/virtual.mjs.map +1 -0
  305. package/dist/schemas/fs.cjs +232 -0
  306. package/dist/schemas/fs.d.cts +127 -0
  307. package/dist/schemas/fs.d.cts.map +1 -0
  308. package/dist/schemas/fs.d.mts +127 -0
  309. package/dist/schemas/fs.d.mts.map +1 -0
  310. package/dist/schemas/fs.mjs +226 -0
  311. package/dist/schemas/fs.mjs.map +1 -0
  312. package/dist/storage/base.cjs +216 -0
  313. package/dist/storage/base.d.cts +201 -0
  314. package/dist/storage/base.d.cts.map +1 -0
  315. package/dist/storage/base.d.mts +201 -0
  316. package/dist/storage/base.d.mts.map +1 -0
  317. package/dist/storage/base.mjs +215 -0
  318. package/dist/storage/base.mjs.map +1 -0
  319. package/dist/storage/file-system.cjs +180 -0
  320. package/dist/storage/file-system.d.cts +129 -0
  321. package/dist/storage/file-system.d.cts.map +1 -0
  322. package/dist/storage/file-system.d.mts +129 -0
  323. package/dist/storage/file-system.d.mts.map +1 -0
  324. package/dist/storage/file-system.mjs +179 -0
  325. package/dist/storage/file-system.mjs.map +1 -0
  326. package/dist/storage/helpers.cjs +37 -0
  327. package/dist/storage/helpers.d.cts +25 -0
  328. package/dist/storage/helpers.d.cts.map +1 -0
  329. package/dist/storage/helpers.d.mts +25 -0
  330. package/dist/storage/helpers.d.mts.map +1 -0
  331. package/dist/storage/helpers.mjs +34 -0
  332. package/dist/storage/helpers.mjs.map +1 -0
  333. package/dist/storage/index.cjs +12 -0
  334. package/dist/storage/index.d.cts +5 -0
  335. package/dist/storage/index.d.mts +5 -0
  336. package/dist/storage/index.mjs +6 -0
  337. package/dist/storage/virtual.cjs +98 -0
  338. package/dist/storage/virtual.d.cts +80 -0
  339. package/dist/storage/virtual.d.cts.map +1 -0
  340. package/dist/storage/virtual.d.mts +80 -0
  341. package/dist/storage/virtual.d.mts.map +1 -0
  342. package/dist/storage/virtual.mjs +97 -0
  343. package/dist/storage/virtual.mjs.map +1 -0
  344. package/dist/types/api.d.cts +18 -152
  345. package/dist/types/api.d.cts.map +1 -1
  346. package/dist/types/api.d.mts +18 -152
  347. package/dist/types/api.d.mts.map +1 -1
  348. package/dist/types/config.d.cts +194 -135
  349. package/dist/types/config.d.cts.map +1 -1
  350. package/dist/types/config.d.mts +195 -136
  351. package/dist/types/config.d.mts.map +1 -1
  352. package/dist/types/context.d.cts +140 -130
  353. package/dist/types/context.d.cts.map +1 -1
  354. package/dist/types/context.d.mts +143 -133
  355. package/dist/types/context.d.mts.map +1 -1
  356. package/dist/types/fs.d.mts +1 -1
  357. package/dist/types/index.d.cts +5 -6
  358. package/dist/types/index.d.mts +5 -6
  359. package/dist/types/logging.d.cts +161 -0
  360. package/dist/types/logging.d.cts.map +1 -0
  361. package/dist/types/logging.d.mts +161 -0
  362. package/dist/types/logging.d.mts.map +1 -0
  363. package/dist/types/plugin.d.cts +6 -9
  364. package/dist/types/plugin.d.cts.map +1 -1
  365. package/dist/types/plugin.d.mts +6 -9
  366. package/dist/types/plugin.d.mts.map +1 -1
  367. package/dist/types/tsconfig.d.mts +1 -1
  368. package/dist/types/unplugin.d.cts +6 -27
  369. package/dist/types/unplugin.d.cts.map +1 -1
  370. package/dist/types/unplugin.d.mts +6 -27
  371. package/dist/types/unplugin.d.mts.map +1 -1
  372. package/package.json +259 -457
  373. package/schemas/fs.capnp +42 -0
  374. package/dist/constants/virtual-modules.cjs +0 -8
  375. package/dist/constants/virtual-modules.d.cts +0 -6
  376. package/dist/constants/virtual-modules.d.cts.map +0 -1
  377. package/dist/constants/virtual-modules.d.mts +0 -6
  378. package/dist/constants/virtual-modules.d.mts.map +0 -1
  379. package/dist/constants/virtual-modules.mjs +0 -7
  380. package/dist/constants/virtual-modules.mjs.map +0 -1
  381. package/dist/lib/logger.cjs +0 -99
  382. package/dist/lib/logger.d.cts +0 -53
  383. package/dist/lib/logger.d.cts.map +0 -1
  384. package/dist/lib/logger.d.mts +0 -53
  385. package/dist/lib/logger.d.mts.map +0 -1
  386. package/dist/lib/logger.mjs +0 -93
  387. package/dist/lib/logger.mjs.map +0 -1
  388. package/dist/types/_internal.cjs +0 -0
  389. package/dist/types/_internal.d.cts +0 -106
  390. package/dist/types/_internal.d.cts.map +0 -1
  391. package/dist/types/_internal.d.mts +0 -106
  392. package/dist/types/_internal.d.mts.map +0 -1
  393. package/dist/types/_internal.mjs +0 -1
  394. package/dist/types/commands.d.cts +0 -16
  395. package/dist/types/commands.d.cts.map +0 -1
  396. package/dist/types/commands.d.mts +0 -16
  397. package/dist/types/commands.d.mts.map +0 -1
  398. package/dist/types/utils.d.cts +0 -9
  399. package/dist/types/utils.d.cts.map +0 -1
  400. package/dist/types/utils.d.mts +0 -9
  401. package/dist/types/utils.d.mts.map +0 -1
@@ -1,9 +1,9 @@
1
1
  import { getHookHandler, isPluginHook } from "./helpers.mjs";
2
2
  import defu, { createDefu } from "defu";
3
- import { getUnique } from "@stryke/helpers/get-unique";
4
3
  import { isSetString } from "@stryke/type-checks/is-set-string";
5
4
  import { isString } from "@stryke/type-checks/is-string";
6
5
  import { isSet } from "@stryke/type-checks/is-set";
6
+ import { getUnique } from "@stryke/helpers/get-unique";
7
7
  import { isSetArray } from "@stryke/type-checks/is-set-array";
8
8
 
9
9
  //#region src/plugin-utils/merge.ts
@@ -9,7 +9,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
9
9
  * @returns `true` if the module is a built-in module, otherwise `false`.
10
10
  */
11
11
  function isBuiltinModule(context, moduleName) {
12
- const prefix = context.config?.framework || "powerlines";
12
+ const prefix = context.config?.framework?.name || "powerlines";
13
13
  return moduleName.startsWith(`${prefix.replace(/:$/, "")}:`) || Object.keys(context.fs.metadata).filter((key) => context.fs.metadata[key]?.type === "builtin").includes(moduleName);
14
14
  }
15
15
 
@@ -7,7 +7,7 @@
7
7
  * @returns `true` if the module is a built-in module, otherwise `false`.
8
8
  */
9
9
  function isBuiltinModule(context, moduleName) {
10
- const prefix = context.config?.framework || "powerlines";
10
+ const prefix = context.config?.framework?.name || "powerlines";
11
11
  return moduleName.startsWith(`${prefix.replace(/:$/, "")}:`) || Object.keys(context.fs.metadata).filter((key) => context.fs.metadata[key]?.type === "builtin").includes(moduleName);
12
12
  }
13
13
 
@@ -1 +1 @@
1
- {"version":3,"file":"modules.mjs","names":[],"sources":["../../src/plugin-utils/modules.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { Context } from \"../types/context\";\n\n/**\n * Determine if a module ID is a built-in Powerlines module ID.\n *\n * @param context - The Powerlines context.\n * @param moduleName - The name of the module to check.\n * @returns `true` if the module is a built-in module, otherwise `false`.\n */\nexport function isBuiltinModule(context: Context, moduleName: string): boolean {\n const prefix: string = context.config?.framework || \"powerlines\";\n\n return (\n moduleName.startsWith(`${prefix.replace(/:$/, \"\")}:`) ||\n Object.keys(context.fs.metadata)\n .filter(key => context.fs.metadata[key]?.type === \"builtin\")\n .includes(moduleName)\n );\n}\n"],"mappings":";;;;;;;;AA2BA,SAAgB,gBAAgB,SAAkB,YAA6B;CAC7E,MAAM,SAAiB,QAAQ,QAAQ,aAAa;AAEpD,QACE,WAAW,WAAW,GAAG,OAAO,QAAQ,MAAM,GAAG,CAAC,GAAG,IACrD,OAAO,KAAK,QAAQ,GAAG,SAAS,CAC7B,QAAO,QAAO,QAAQ,GAAG,SAAS,MAAM,SAAS,UAAU,CAC3D,SAAS,WAAW"}
1
+ {"version":3,"file":"modules.mjs","names":[],"sources":["../../src/plugin-utils/modules.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { Context } from \"../types/context\";\n\n/**\n * Determine if a module ID is a built-in Powerlines module ID.\n *\n * @param context - The Powerlines context.\n * @param moduleName - The name of the module to check.\n * @returns `true` if the module is a built-in module, otherwise `false`.\n */\nexport function isBuiltinModule(context: Context, moduleName: string): boolean {\n const prefix: string = context.config?.framework?.name || \"powerlines\";\n\n return (\n moduleName.startsWith(`${prefix.replace(/:$/, \"\")}:`) ||\n Object.keys(context.fs.metadata)\n .filter(key => context.fs.metadata[key]?.type === \"builtin\")\n .includes(moduleName)\n );\n}\n"],"mappings":";;;;;;;;AA2BA,SAAgB,gBAAgB,SAAkB,YAA6B;CAC7E,MAAM,SAAiB,QAAQ,QAAQ,WAAW,QAAQ;AAE1D,QACE,WAAW,WAAW,GAAG,OAAO,QAAQ,MAAM,GAAG,CAAC,GAAG,IACrD,OAAO,KAAK,QAAQ,GAAG,SAAS,CAC7B,QAAO,QAAO,QAAQ,GAAG,SAAS,MAAM,SAAS,UAAU,CAC3D,SAAS,WAAW"}
@@ -44,8 +44,12 @@ let _stryke_path_join = require("@stryke/path/join");
44
44
  */
45
45
  function replacePathTokens(context, path) {
46
46
  if (!path) return path;
47
- const result = path.replaceAll("{cwd}", context.config.cwd || process.cwd() || "./").replaceAll("{workspaceRoot}", context.config.cwd || process.cwd() || "./").replaceAll("{root}", context.config.root).replaceAll("{projectRoot}", context.config.root).replaceAll("{sourceRoot}", (0, _stryke_path_join.joinPaths)(context.config.root, "src")).replaceAll("{powerlinesPath}", context.powerlinesPath).replaceAll("{cachePath}", context.cachePath).replaceAll("{dataPath}", context.dataPath).replaceAll("{logPath}", context.envPaths.log).replaceAll("{tempPath}", context.envPaths.temp).replaceAll("{configPath}", context.envPaths.config).replaceAll("{outputPath}", context.config.output.path).replaceAll("{output}", context.config.output.path).replaceAll("{artifactsPath}", (0, _stryke_path_replace.replacePath)(context.artifactsPath, context.config.cwd)).replaceAll("{builtinPath}", (0, _stryke_path_replace.replacePath)(context.builtinsPath, context.config.cwd)).replaceAll("{builtinsPath}", (0, _stryke_path_replace.replacePath)(context.builtinsPath, context.config.cwd)).replaceAll("{entryPath}", (0, _stryke_path_replace.replacePath)(context.entryPath, context.config.cwd));
48
- return context.config.output.copy && (0, _stryke_type_checks_is_set_string.isSetString)(context.config.output.copy.path) ? result.replaceAll("{copyPath}", context.config.output.copy.path).replaceAll("{copy}", context.config.output.copy.path) : result;
47
+ let result = path.replaceAll("{cwd}", context.config.cwd || process.cwd()).replaceAll("{workspaceRoot}", context.config.cwd || process.cwd()).replaceAll("{root}", context.config.root).replaceAll("{projectRoot}", context.config.root).replaceAll("{sourceRoot}", (0, _stryke_path_join.joinPaths)(context.config.root, "src")).replaceAll("{powerlinesPath}", context.powerlinesPath).replaceAll("{cachePath}", context.cachePath).replaceAll("{dataPath}", context.dataPath).replaceAll("{logPath}", context.envPaths.log).replaceAll("{tempPath}", context.envPaths.temp).replaceAll("{configPath}", context.envPaths.config).replaceAll("{artifactsPath}", (0, _stryke_path_replace.replacePath)(context.artifactsPath, context.config.cwd)).replaceAll("{builtinPath}", (0, _stryke_path_replace.replacePath)(context.builtinsPath, context.config.cwd)).replaceAll("{builtinsPath}", (0, _stryke_path_replace.replacePath)(context.builtinsPath, context.config.cwd)).replaceAll("{entryPath}", (0, _stryke_path_replace.replacePath)(context.entryPath, context.config.cwd));
48
+ if (context.config.output) {
49
+ if ((0, _stryke_type_checks_is_set_string.isSetString)(context.config.output.path)) result = result.replaceAll("{outputPath}", context.config.output.path).replaceAll("{output}", context.config.output.path);
50
+ if (context.config.output.copy && (0, _stryke_type_checks_is_set_string.isSetString)(context.config.output.copy?.path)) result = result.replaceAll("{copyPath}", context.config.output.copy.path).replaceAll("{copy}", context.config.output.copy.path);
51
+ }
52
+ return result;
49
53
  }
50
54
 
51
55
  //#endregion
@@ -42,8 +42,12 @@ import { joinPaths } from "@stryke/path/join";
42
42
  */
43
43
  function replacePathTokens(context, path) {
44
44
  if (!path) return path;
45
- const result = path.replaceAll("{cwd}", context.config.cwd || process.cwd() || "./").replaceAll("{workspaceRoot}", context.config.cwd || process.cwd() || "./").replaceAll("{root}", context.config.root).replaceAll("{projectRoot}", context.config.root).replaceAll("{sourceRoot}", joinPaths(context.config.root, "src")).replaceAll("{powerlinesPath}", context.powerlinesPath).replaceAll("{cachePath}", context.cachePath).replaceAll("{dataPath}", context.dataPath).replaceAll("{logPath}", context.envPaths.log).replaceAll("{tempPath}", context.envPaths.temp).replaceAll("{configPath}", context.envPaths.config).replaceAll("{outputPath}", context.config.output.path).replaceAll("{output}", context.config.output.path).replaceAll("{artifactsPath}", replacePath(context.artifactsPath, context.config.cwd)).replaceAll("{builtinPath}", replacePath(context.builtinsPath, context.config.cwd)).replaceAll("{builtinsPath}", replacePath(context.builtinsPath, context.config.cwd)).replaceAll("{entryPath}", replacePath(context.entryPath, context.config.cwd));
46
- return context.config.output.copy && isSetString(context.config.output.copy.path) ? result.replaceAll("{copyPath}", context.config.output.copy.path).replaceAll("{copy}", context.config.output.copy.path) : result;
45
+ let result = path.replaceAll("{cwd}", context.config.cwd || process.cwd()).replaceAll("{workspaceRoot}", context.config.cwd || process.cwd()).replaceAll("{root}", context.config.root).replaceAll("{projectRoot}", context.config.root).replaceAll("{sourceRoot}", joinPaths(context.config.root, "src")).replaceAll("{powerlinesPath}", context.powerlinesPath).replaceAll("{cachePath}", context.cachePath).replaceAll("{dataPath}", context.dataPath).replaceAll("{logPath}", context.envPaths.log).replaceAll("{tempPath}", context.envPaths.temp).replaceAll("{configPath}", context.envPaths.config).replaceAll("{artifactsPath}", replacePath(context.artifactsPath, context.config.cwd)).replaceAll("{builtinPath}", replacePath(context.builtinsPath, context.config.cwd)).replaceAll("{builtinsPath}", replacePath(context.builtinsPath, context.config.cwd)).replaceAll("{entryPath}", replacePath(context.entryPath, context.config.cwd));
46
+ if (context.config.output) {
47
+ if (isSetString(context.config.output.path)) result = result.replaceAll("{outputPath}", context.config.output.path).replaceAll("{output}", context.config.output.path);
48
+ if (context.config.output.copy && isSetString(context.config.output.copy?.path)) result = result.replaceAll("{copyPath}", context.config.output.copy.path).replaceAll("{copy}", context.config.output.copy.path);
49
+ }
50
+ return result;
47
51
  }
48
52
 
49
53
  //#endregion
@@ -1 +1 @@
1
- {"version":3,"file":"paths.mjs","names":[],"sources":["../../src/plugin-utils/paths.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { joinPaths } from \"@stryke/path/join\";\nimport { replacePath } from \"@stryke/path/replace\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport { IsUndefined } from \"@stryke/types/base\";\nimport { UnresolvedContext } from \"../types/context\";\n\n/**\n * Replaces tokens in the given path string with their corresponding values from the context.\n *\n * @remarks\n * The following tokens are supported:\n * - `{cwd}` - The current working directory.\n * - `{workspaceRoot}` - The current working directory (same as `{cwd}`).\n * - `{root}` - The root directory of the project (same as `{projectRoot}`).\n * - `{projectRoot}` - The root directory of the project (same as `{root}`).\n * - `{sourceRoot}` - The source root directory of the project (usually `{root}/src`).\n * - `{powerlinesPath}` - The directory where Powerlines is installed.\n * - `{cachePath}` - The environment's directory for cached files.\n * - `{dataPath}` - The environment's directory for data files.\n * - `{logPath}` - The environment's directory for log files.\n * - `{tempPath}` - The environment's directory for temporary files.\n * - `{configPath}` - The environment's directory for configuration files.\n * - `{output}` - The configured output directory for the project.\n * - `{outputPath}` - The configured output directory for the project.\n * - `{copy}` - The configured final/copied distribution directory for the project.\n * - `{copyPath}` - The configured final/copied distribution directory for the project.\n * - `{artifactsPath}` - The configured directory for build artifacts.\n * - `{builtinPath}` - The configured directory for generated built-in plugins.\n * - `{entryPath}` - The configured directory for generated entry files.\n *\n * @example\n * ```ts\n * const path = replacePathTokens(context, \"{root}/dist\");\n * // If context.config.root is \"/home/user/project\", this will return \"/home/user/project/dist\"\n *\n * const pathWithCopy = replacePathTokens(context, \"{copy}\");\n * // If context.config.output.copy.path is \"/home/user/project/dist-copy\", this will return \"/home/user/project/dist-copy\"\n * ```\n *\n * @param context - The context containing the values for the path tokens.\n * @param path - The path string with tokens to replace.\n * @returns The path string with tokens replaced by their corresponding values from the context.\n */\nexport function replacePathTokens(\n context: UnresolvedContext,\n path?: string\n): IsUndefined<typeof path> extends true ? undefined : string {\n if (!path) {\n return path as IsUndefined<typeof path> extends true ? undefined : string;\n }\n\n const result = path\n .replaceAll(\"{cwd}\", context.config.cwd || process.cwd() || \"./\")\n .replaceAll(\"{workspaceRoot}\", context.config.cwd || process.cwd() || \"./\")\n .replaceAll(\"{root}\", context.config.root)\n .replaceAll(\"{projectRoot}\", context.config.root)\n .replaceAll(\"{sourceRoot}\", joinPaths(context.config.root, \"src\"))\n .replaceAll(\"{powerlinesPath}\", context.powerlinesPath)\n .replaceAll(\"{cachePath}\", context.cachePath)\n .replaceAll(\"{dataPath}\", context.dataPath)\n .replaceAll(\"{logPath}\", context.envPaths.log)\n .replaceAll(\"{tempPath}\", context.envPaths.temp)\n .replaceAll(\"{configPath}\", context.envPaths.config)\n .replaceAll(\"{outputPath}\", context.config.output.path)\n .replaceAll(\"{output}\", context.config.output.path)\n\n .replaceAll(\n \"{artifactsPath}\",\n replacePath(context.artifactsPath, context.config.cwd)\n )\n .replaceAll(\n \"{builtinPath}\",\n replacePath(context.builtinsPath, context.config.cwd)\n )\n .replaceAll(\n \"{builtinsPath}\",\n replacePath(context.builtinsPath, context.config.cwd)\n )\n .replaceAll(\n \"{entryPath}\",\n replacePath(context.entryPath, context.config.cwd)\n );\n\n return context.config.output.copy &&\n isSetString(context.config.output.copy.path)\n ? result\n .replaceAll(\"{copyPath}\", context.config.output.copy.path)\n .replaceAll(\"{copy}\", context.config.output.copy.path)\n : result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6DA,SAAgB,kBACd,SACA,MAC4D;AAC5D,KAAI,CAAC,KACH,QAAO;CAGT,MAAM,SAAS,KACZ,WAAW,SAAS,QAAQ,OAAO,OAAO,QAAQ,KAAK,IAAI,KAAK,CAChE,WAAW,mBAAmB,QAAQ,OAAO,OAAO,QAAQ,KAAK,IAAI,KAAK,CAC1E,WAAW,UAAU,QAAQ,OAAO,KAAK,CACzC,WAAW,iBAAiB,QAAQ,OAAO,KAAK,CAChD,WAAW,gBAAgB,UAAU,QAAQ,OAAO,MAAM,MAAM,CAAC,CACjE,WAAW,oBAAoB,QAAQ,eAAe,CACtD,WAAW,eAAe,QAAQ,UAAU,CAC5C,WAAW,cAAc,QAAQ,SAAS,CAC1C,WAAW,aAAa,QAAQ,SAAS,IAAI,CAC7C,WAAW,cAAc,QAAQ,SAAS,KAAK,CAC/C,WAAW,gBAAgB,QAAQ,SAAS,OAAO,CACnD,WAAW,gBAAgB,QAAQ,OAAO,OAAO,KAAK,CACtD,WAAW,YAAY,QAAQ,OAAO,OAAO,KAAK,CAElD,WACC,mBACA,YAAY,QAAQ,eAAe,QAAQ,OAAO,IAAI,CACvD,CACA,WACC,iBACA,YAAY,QAAQ,cAAc,QAAQ,OAAO,IAAI,CACtD,CACA,WACC,kBACA,YAAY,QAAQ,cAAc,QAAQ,OAAO,IAAI,CACtD,CACA,WACC,eACA,YAAY,QAAQ,WAAW,QAAQ,OAAO,IAAI,CACnD;AAEH,QAAO,QAAQ,OAAO,OAAO,QAC3B,YAAY,QAAQ,OAAO,OAAO,KAAK,KAAK,GAC1C,OACG,WAAW,cAAc,QAAQ,OAAO,OAAO,KAAK,KAAK,CACzD,WAAW,UAAU,QAAQ,OAAO,OAAO,KAAK,KAAK,GACxD"}
1
+ {"version":3,"file":"paths.mjs","names":[],"sources":["../../src/plugin-utils/paths.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nimport { joinPaths } from \"@stryke/path/join\";\nimport { replacePath } from \"@stryke/path/replace\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport { IsUndefined } from \"@stryke/types/base\";\nimport { UnresolvedContext } from \"../types/context\";\n\n/**\n * Replaces tokens in the given path string with their corresponding values from the context.\n *\n * @remarks\n * The following tokens are supported:\n * - `{cwd}` - The current working directory.\n * - `{workspaceRoot}` - The current working directory (same as `{cwd}`).\n * - `{root}` - The root directory of the project (same as `{projectRoot}`).\n * - `{projectRoot}` - The root directory of the project (same as `{root}`).\n * - `{sourceRoot}` - The source root directory of the project (usually `{root}/src`).\n * - `{powerlinesPath}` - The directory where Powerlines is installed.\n * - `{cachePath}` - The environment's directory for cached files.\n * - `{dataPath}` - The environment's directory for data files.\n * - `{logPath}` - The environment's directory for log files.\n * - `{tempPath}` - The environment's directory for temporary files.\n * - `{configPath}` - The environment's directory for configuration files.\n * - `{output}` - The configured output directory for the project.\n * - `{outputPath}` - The configured output directory for the project.\n * - `{copy}` - The configured final/copied distribution directory for the project.\n * - `{copyPath}` - The configured final/copied distribution directory for the project.\n * - `{artifactsPath}` - The configured directory for build artifacts.\n * - `{builtinPath}` - The configured directory for generated built-in plugins.\n * - `{entryPath}` - The configured directory for generated entry files.\n *\n * @example\n * ```ts\n * const path = replacePathTokens(context, \"{root}/dist\");\n * // If context.config.root is \"/home/user/project\", this will return \"/home/user/project/dist\"\n *\n * const pathWithCopy = replacePathTokens(context, \"{copy}\");\n * // If context.config.output.copy.path is \"/home/user/project/dist-copy\", this will return \"/home/user/project/dist-copy\"\n * ```\n *\n * @param context - The context containing the values for the path tokens.\n * @param path - The path string with tokens to replace.\n * @returns The path string with tokens replaced by their corresponding values from the context.\n */\nexport function replacePathTokens(\n context: UnresolvedContext,\n path?: string\n): IsUndefined<typeof path> extends true ? undefined : string {\n if (!path) {\n return path as IsUndefined<typeof path> extends true ? undefined : string;\n }\n\n let result = path\n .replaceAll(\"{cwd}\", context.config.cwd || process.cwd())\n .replaceAll(\"{workspaceRoot}\", context.config.cwd || process.cwd())\n .replaceAll(\"{root}\", context.config.root)\n .replaceAll(\"{projectRoot}\", context.config.root)\n .replaceAll(\"{sourceRoot}\", joinPaths(context.config.root, \"src\"))\n .replaceAll(\"{powerlinesPath}\", context.powerlinesPath)\n .replaceAll(\"{cachePath}\", context.cachePath)\n .replaceAll(\"{dataPath}\", context.dataPath)\n .replaceAll(\"{logPath}\", context.envPaths.log)\n .replaceAll(\"{tempPath}\", context.envPaths.temp)\n .replaceAll(\"{configPath}\", context.envPaths.config)\n .replaceAll(\n \"{artifactsPath}\",\n replacePath(context.artifactsPath, context.config.cwd)\n )\n .replaceAll(\n \"{builtinPath}\",\n replacePath(context.builtinsPath, context.config.cwd)\n )\n .replaceAll(\n \"{builtinsPath}\",\n replacePath(context.builtinsPath, context.config.cwd)\n )\n .replaceAll(\n \"{entryPath}\",\n replacePath(context.entryPath, context.config.cwd)\n );\n\n if (context.config.output) {\n if (isSetString(context.config.output.path)) {\n result = result\n .replaceAll(\"{outputPath}\", context.config.output.path)\n .replaceAll(\"{output}\", context.config.output.path);\n }\n if (\n context.config.output.copy &&\n isSetString(context.config.output.copy?.path)\n ) {\n result = result\n .replaceAll(\"{copyPath}\", context.config.output.copy.path)\n .replaceAll(\"{copy}\", context.config.output.copy.path);\n }\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA6DA,SAAgB,kBACd,SACA,MAC4D;AAC5D,KAAI,CAAC,KACH,QAAO;CAGT,IAAI,SAAS,KACV,WAAW,SAAS,QAAQ,OAAO,OAAO,QAAQ,KAAK,CAAC,CACxD,WAAW,mBAAmB,QAAQ,OAAO,OAAO,QAAQ,KAAK,CAAC,CAClE,WAAW,UAAU,QAAQ,OAAO,KAAK,CACzC,WAAW,iBAAiB,QAAQ,OAAO,KAAK,CAChD,WAAW,gBAAgB,UAAU,QAAQ,OAAO,MAAM,MAAM,CAAC,CACjE,WAAW,oBAAoB,QAAQ,eAAe,CACtD,WAAW,eAAe,QAAQ,UAAU,CAC5C,WAAW,cAAc,QAAQ,SAAS,CAC1C,WAAW,aAAa,QAAQ,SAAS,IAAI,CAC7C,WAAW,cAAc,QAAQ,SAAS,KAAK,CAC/C,WAAW,gBAAgB,QAAQ,SAAS,OAAO,CACnD,WACC,mBACA,YAAY,QAAQ,eAAe,QAAQ,OAAO,IAAI,CACvD,CACA,WACC,iBACA,YAAY,QAAQ,cAAc,QAAQ,OAAO,IAAI,CACtD,CACA,WACC,kBACA,YAAY,QAAQ,cAAc,QAAQ,OAAO,IAAI,CACtD,CACA,WACC,eACA,YAAY,QAAQ,WAAW,QAAQ,OAAO,IAAI,CACnD;AAEH,KAAI,QAAQ,OAAO,QAAQ;AACzB,MAAI,YAAY,QAAQ,OAAO,OAAO,KAAK,CACzC,UAAS,OACN,WAAW,gBAAgB,QAAQ,OAAO,OAAO,KAAK,CACtD,WAAW,YAAY,QAAQ,OAAO,OAAO,KAAK;AAEvD,MACE,QAAQ,OAAO,OAAO,QACtB,YAAY,QAAQ,OAAO,OAAO,MAAM,KAAK,CAE7C,UAAS,OACN,WAAW,cAAc,QAAQ,OAAO,OAAO,KAAK,KAAK,CACzD,WAAW,UAAU,QAAQ,OAAO,OAAO,KAAK,KAAK;;AAI5D,QAAO"}
@@ -0,0 +1,80 @@
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+
3
+ //#region src/plugin-utils/virtual.ts
4
+ const ESCAPE_REGEX = /[-/\\^$*+?.()|[\]{}]/g;
5
+ function escapeRegex(str) {
6
+ return str.replace(ESCAPE_REGEX, "\\$&");
7
+ }
8
+ const VIRTUAL_MODULE_PREFIX = "\0";
9
+ const VIRTUAL_MODULE_PREFIX_REGEX = prefixRegex("\0");
10
+ /**
11
+ * Constructs a RegExp that matches a value that has the specified prefix. This is useful for plugin hook filters.
12
+ *
13
+ * @example
14
+ * ```ts
15
+ * import { prefixRegex } from '@rolldown/pluginutils';
16
+ * const plugin = {
17
+ * name: 'plugin',
18
+ * resolveId: {
19
+ * filter: { id: prefixRegex('foo') },
20
+ * handler(id) {} // will only be called for IDs starting with `foo`
21
+ * }
22
+ * }
23
+ * ```
24
+ *
25
+ * @param str - the string to match.
26
+ * @param options - options for the RegExp.
27
+ * @return a RegExp that matches the specified string with the specified prefix.
28
+ */
29
+ function prefixRegex(str, options = {}) {
30
+ const { flags, prefix, isPrefixOptional = false } = options;
31
+ return new RegExp(`^${prefix ? isPrefixOptional ? `(${escapeRegex(prefix)})?` : `${escapeRegex(prefix)}` : ""}${escapeRegex(str)}`, flags);
32
+ }
33
+ /**
34
+ * Adds the virtual module prefix to the given ID.
35
+ *
36
+ * @param id - The ID to add the virtual module prefix to.
37
+ * @returns The ID with the virtual module prefix added.
38
+ */
39
+ function addVirtualPrefix(id) {
40
+ return `${"\0"}${id}`;
41
+ }
42
+ /**
43
+ * Removes the virtual module prefix from the given ID, if it exists.
44
+ *
45
+ * @param id - The ID to remove the virtual module prefix from.
46
+ * @returns The ID without the virtual module prefix.
47
+ */
48
+ function removeVirtualPrefix(id) {
49
+ return id.replace(VIRTUAL_MODULE_PREFIX_REGEX, "");
50
+ }
51
+ /**
52
+ * Checks if the given ID is a virtual module by checking if it starts with the virtual module prefix.
53
+ *
54
+ * @param id - The ID to check.
55
+ * @returns True if the ID is a virtual module, false otherwise.
56
+ */
57
+ function isVirtualModule(id) {
58
+ return id.startsWith("\0");
59
+ }
60
+ /**
61
+ * Creates a regular expression that matches the given ID with the virtual module prefix.
62
+ *
63
+ * @param id - The ID to create a regular expression for.
64
+ * @returns A regular expression that matches the given ID with the virtual module prefix.
65
+ */
66
+ function createVirtualPrefixRegex(id) {
67
+ return prefixRegex(removeVirtualPrefix(id), {
68
+ prefix: "\0",
69
+ isPrefixOptional: true
70
+ });
71
+ }
72
+
73
+ //#endregion
74
+ exports.VIRTUAL_MODULE_PREFIX = VIRTUAL_MODULE_PREFIX;
75
+ exports.VIRTUAL_MODULE_PREFIX_REGEX = VIRTUAL_MODULE_PREFIX_REGEX;
76
+ exports.addVirtualPrefix = addVirtualPrefix;
77
+ exports.createVirtualPrefixRegex = createVirtualPrefixRegex;
78
+ exports.isVirtualModule = isVirtualModule;
79
+ exports.prefixRegex = prefixRegex;
80
+ exports.removeVirtualPrefix = removeVirtualPrefix;
@@ -0,0 +1,69 @@
1
+ //#region src/plugin-utils/virtual.d.ts
2
+ declare const VIRTUAL_MODULE_PREFIX = "\0";
3
+ declare const VIRTUAL_MODULE_PREFIX_REGEX: RegExp;
4
+ interface PrefixRegexOptions {
5
+ /**
6
+ * Flags for the RegExp.
7
+ */
8
+ flags?: string;
9
+ /**
10
+ * The prefix to match. This will be escaped and used as the prefix in the generated RegExp.
11
+ */
12
+ prefix?: string;
13
+ /**
14
+ * Whether the prefix is optional. If true, the generated RegExp will match both strings that start with the prefix and strings that do not start with the prefix. Default is false.
15
+ */
16
+ isPrefixOptional?: boolean;
17
+ }
18
+ /**
19
+ * Constructs a RegExp that matches a value that has the specified prefix. This is useful for plugin hook filters.
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * import { prefixRegex } from '@rolldown/pluginutils';
24
+ * const plugin = {
25
+ * name: 'plugin',
26
+ * resolveId: {
27
+ * filter: { id: prefixRegex('foo') },
28
+ * handler(id) {} // will only be called for IDs starting with `foo`
29
+ * }
30
+ * }
31
+ * ```
32
+ *
33
+ * @param str - the string to match.
34
+ * @param options - options for the RegExp.
35
+ * @return a RegExp that matches the specified string with the specified prefix.
36
+ */
37
+ declare function prefixRegex(str: string, options?: PrefixRegexOptions): RegExp;
38
+ /**
39
+ * Adds the virtual module prefix to the given ID.
40
+ *
41
+ * @param id - The ID to add the virtual module prefix to.
42
+ * @returns The ID with the virtual module prefix added.
43
+ */
44
+ declare function addVirtualPrefix(id: string): string;
45
+ /**
46
+ * Removes the virtual module prefix from the given ID, if it exists.
47
+ *
48
+ * @param id - The ID to remove the virtual module prefix from.
49
+ * @returns The ID without the virtual module prefix.
50
+ */
51
+ declare function removeVirtualPrefix(id: string): string;
52
+ /**
53
+ * Checks if the given ID is a virtual module by checking if it starts with the virtual module prefix.
54
+ *
55
+ * @param id - The ID to check.
56
+ * @returns True if the ID is a virtual module, false otherwise.
57
+ */
58
+ declare function isVirtualModule(id: string): boolean;
59
+ /**
60
+ * Creates a regular expression that matches the given ID with the virtual module prefix.
61
+ *
62
+ * @param id - The ID to create a regular expression for.
63
+ * @returns A regular expression that matches the given ID with the virtual module prefix.
64
+ */
65
+ declare function createVirtualPrefixRegex(id: string): RegExp;
66
+ declare type __ΩPrefixRegexOptions = any[];
67
+ //#endregion
68
+ export { PrefixRegexOptions, VIRTUAL_MODULE_PREFIX, VIRTUAL_MODULE_PREFIX_REGEX, __ΩPrefixRegexOptions, addVirtualPrefix, createVirtualPrefixRegex, isVirtualModule, prefixRegex, removeVirtualPrefix };
69
+ //# sourceMappingURL=virtual.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"virtual.d.cts","names":[],"sources":["../../src/plugin-utils/virtual.ts"],"mappings":";cAuBa,qBAAA;AAAA,cACA,2BAAA,EAA2B,MAAA;AAAA,UAEvB,kBAAA;;;;EAIf,KAAA;EAN0D;;;EAW1D,MAAA;EATe;;;EAcf,gBAAA;AAAA;;;;;AAsBF;;;;;;;;;;AAwBA;;;;;iBAxBgB,WAAA,CACd,GAAA,UACA,OAAA,GAAS,kBAAA,GACR,MAAA;;;;;AAyCH;;iBApBgB,gBAAA,CAAiB,EAAA;;;AA8BjC;;;;iBApBgB,mBAAA,CAAoB,EAAA;;;;;;;iBAUpB,eAAA,CAAgB,EAAA;;;;;;;iBAUhB,wBAAA,CAAyB,EAAA,WAAa,MAAA;AAAA"}
@@ -0,0 +1,69 @@
1
+ //#region src/plugin-utils/virtual.d.ts
2
+ declare const VIRTUAL_MODULE_PREFIX = "\0";
3
+ declare const VIRTUAL_MODULE_PREFIX_REGEX: RegExp;
4
+ interface PrefixRegexOptions {
5
+ /**
6
+ * Flags for the RegExp.
7
+ */
8
+ flags?: string;
9
+ /**
10
+ * The prefix to match. This will be escaped and used as the prefix in the generated RegExp.
11
+ */
12
+ prefix?: string;
13
+ /**
14
+ * Whether the prefix is optional. If true, the generated RegExp will match both strings that start with the prefix and strings that do not start with the prefix. Default is false.
15
+ */
16
+ isPrefixOptional?: boolean;
17
+ }
18
+ /**
19
+ * Constructs a RegExp that matches a value that has the specified prefix. This is useful for plugin hook filters.
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * import { prefixRegex } from '@rolldown/pluginutils';
24
+ * const plugin = {
25
+ * name: 'plugin',
26
+ * resolveId: {
27
+ * filter: { id: prefixRegex('foo') },
28
+ * handler(id) {} // will only be called for IDs starting with `foo`
29
+ * }
30
+ * }
31
+ * ```
32
+ *
33
+ * @param str - the string to match.
34
+ * @param options - options for the RegExp.
35
+ * @return a RegExp that matches the specified string with the specified prefix.
36
+ */
37
+ declare function prefixRegex(str: string, options?: PrefixRegexOptions): RegExp;
38
+ /**
39
+ * Adds the virtual module prefix to the given ID.
40
+ *
41
+ * @param id - The ID to add the virtual module prefix to.
42
+ * @returns The ID with the virtual module prefix added.
43
+ */
44
+ declare function addVirtualPrefix(id: string): string;
45
+ /**
46
+ * Removes the virtual module prefix from the given ID, if it exists.
47
+ *
48
+ * @param id - The ID to remove the virtual module prefix from.
49
+ * @returns The ID without the virtual module prefix.
50
+ */
51
+ declare function removeVirtualPrefix(id: string): string;
52
+ /**
53
+ * Checks if the given ID is a virtual module by checking if it starts with the virtual module prefix.
54
+ *
55
+ * @param id - The ID to check.
56
+ * @returns True if the ID is a virtual module, false otherwise.
57
+ */
58
+ declare function isVirtualModule(id: string): boolean;
59
+ /**
60
+ * Creates a regular expression that matches the given ID with the virtual module prefix.
61
+ *
62
+ * @param id - The ID to create a regular expression for.
63
+ * @returns A regular expression that matches the given ID with the virtual module prefix.
64
+ */
65
+ declare function createVirtualPrefixRegex(id: string): RegExp;
66
+ declare type __ΩPrefixRegexOptions = any[];
67
+ //#endregion
68
+ export { PrefixRegexOptions, VIRTUAL_MODULE_PREFIX, VIRTUAL_MODULE_PREFIX_REGEX, __ΩPrefixRegexOptions, addVirtualPrefix, createVirtualPrefixRegex, isVirtualModule, prefixRegex, removeVirtualPrefix };
69
+ //# sourceMappingURL=virtual.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"virtual.d.mts","names":[],"sources":["../../src/plugin-utils/virtual.ts"],"mappings":";cAuBa,qBAAA;AAAA,cACA,2BAAA,EAA2B,MAAA;AAAA,UAEvB,kBAAA;;;;EAIf,KAAA;EAN0D;;;EAW1D,MAAA;EATe;;;EAcf,gBAAA;AAAA;;;;;AAsBF;;;;;;;;;;AAwBA;;;;;iBAxBgB,WAAA,CACd,GAAA,UACA,OAAA,GAAS,kBAAA,GACR,MAAA;;;;;AAyCH;;iBApBgB,gBAAA,CAAiB,EAAA;;;AA8BjC;;;;iBApBgB,mBAAA,CAAoB,EAAA;;;;;;;iBAUpB,eAAA,CAAgB,EAAA;;;;;;;iBAUhB,wBAAA,CAAyB,EAAA,WAAa,MAAA;AAAA"}
@@ -0,0 +1,73 @@
1
+ //#region src/plugin-utils/virtual.ts
2
+ const ESCAPE_REGEX = /[-/\\^$*+?.()|[\]{}]/g;
3
+ function escapeRegex(str) {
4
+ return str.replace(ESCAPE_REGEX, "\\$&");
5
+ }
6
+ const VIRTUAL_MODULE_PREFIX = "\0";
7
+ const VIRTUAL_MODULE_PREFIX_REGEX = prefixRegex("\0");
8
+ /**
9
+ * Constructs a RegExp that matches a value that has the specified prefix. This is useful for plugin hook filters.
10
+ *
11
+ * @example
12
+ * ```ts
13
+ * import { prefixRegex } from '@rolldown/pluginutils';
14
+ * const plugin = {
15
+ * name: 'plugin',
16
+ * resolveId: {
17
+ * filter: { id: prefixRegex('foo') },
18
+ * handler(id) {} // will only be called for IDs starting with `foo`
19
+ * }
20
+ * }
21
+ * ```
22
+ *
23
+ * @param str - the string to match.
24
+ * @param options - options for the RegExp.
25
+ * @return a RegExp that matches the specified string with the specified prefix.
26
+ */
27
+ function prefixRegex(str, options = {}) {
28
+ const { flags, prefix, isPrefixOptional = false } = options;
29
+ return new RegExp(`^${prefix ? isPrefixOptional ? `(${escapeRegex(prefix)})?` : `${escapeRegex(prefix)}` : ""}${escapeRegex(str)}`, flags);
30
+ }
31
+ /**
32
+ * Adds the virtual module prefix to the given ID.
33
+ *
34
+ * @param id - The ID to add the virtual module prefix to.
35
+ * @returns The ID with the virtual module prefix added.
36
+ */
37
+ function addVirtualPrefix(id) {
38
+ return `${"\0"}${id}`;
39
+ }
40
+ /**
41
+ * Removes the virtual module prefix from the given ID, if it exists.
42
+ *
43
+ * @param id - The ID to remove the virtual module prefix from.
44
+ * @returns The ID without the virtual module prefix.
45
+ */
46
+ function removeVirtualPrefix(id) {
47
+ return id.replace(VIRTUAL_MODULE_PREFIX_REGEX, "");
48
+ }
49
+ /**
50
+ * Checks if the given ID is a virtual module by checking if it starts with the virtual module prefix.
51
+ *
52
+ * @param id - The ID to check.
53
+ * @returns True if the ID is a virtual module, false otherwise.
54
+ */
55
+ function isVirtualModule(id) {
56
+ return id.startsWith("\0");
57
+ }
58
+ /**
59
+ * Creates a regular expression that matches the given ID with the virtual module prefix.
60
+ *
61
+ * @param id - The ID to create a regular expression for.
62
+ * @returns A regular expression that matches the given ID with the virtual module prefix.
63
+ */
64
+ function createVirtualPrefixRegex(id) {
65
+ return prefixRegex(removeVirtualPrefix(id), {
66
+ prefix: "\0",
67
+ isPrefixOptional: true
68
+ });
69
+ }
70
+
71
+ //#endregion
72
+ export { VIRTUAL_MODULE_PREFIX, VIRTUAL_MODULE_PREFIX_REGEX, addVirtualPrefix, createVirtualPrefixRegex, isVirtualModule, prefixRegex, removeVirtualPrefix };
73
+ //# sourceMappingURL=virtual.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"virtual.mjs","names":[],"sources":["../../src/plugin-utils/virtual.ts"],"sourcesContent":["/* -------------------------------------------------------------------\n\n ⚡ Storm Software - Powerlines\n\n This code was released as part of the Powerlines project. Powerlines\n is maintained by Storm Software under the Apache-2.0 license, and is\n free for commercial and private use. For more information, please visit\n our licensing page at https://stormsoftware.com/licenses/projects/powerlines.\n\n Website: https://stormsoftware.com\n Repository: https://github.com/storm-software/powerlines\n Documentation: https://docs.stormsoftware.com/projects/powerlines\n Contact: https://stormsoftware.com/contact\n\n SPDX-License-Identifier: Apache-2.0\n\n ------------------------------------------------------------------- */\n\nconst ESCAPE_REGEX = /[-/\\\\^$*+?.()|[\\]{}]/g;\nfunction escapeRegex(str: string): string {\n return str.replace(ESCAPE_REGEX, \"\\\\$&\");\n}\n\nexport const VIRTUAL_MODULE_PREFIX = \"\\0\";\nexport const VIRTUAL_MODULE_PREFIX_REGEX = prefixRegex(\"\\0\");\n\nexport interface PrefixRegexOptions {\n /**\n * Flags for the RegExp.\n */\n flags?: string;\n\n /**\n * The prefix to match. This will be escaped and used as the prefix in the generated RegExp.\n */\n prefix?: string;\n\n /**\n * Whether the prefix is optional. If true, the generated RegExp will match both strings that start with the prefix and strings that do not start with the prefix. Default is false.\n */\n isPrefixOptional?: boolean;\n}\n\n/**\n * Constructs a RegExp that matches a value that has the specified prefix. This is useful for plugin hook filters.\n *\n * @example\n * ```ts\n * import { prefixRegex } from '@rolldown/pluginutils';\n * const plugin = {\n * name: 'plugin',\n * resolveId: {\n * filter: { id: prefixRegex('foo') },\n * handler(id) {} // will only be called for IDs starting with `foo`\n * }\n * }\n * ```\n *\n * @param str - the string to match.\n * @param options - options for the RegExp.\n * @return a RegExp that matches the specified string with the specified prefix.\n */\nexport function prefixRegex(\n str: string,\n options: PrefixRegexOptions = {}\n): RegExp {\n const { flags, prefix, isPrefixOptional = false } = options;\n\n return new RegExp(\n `^${\n prefix\n ? isPrefixOptional\n ? `(${escapeRegex(prefix)})?`\n : `${escapeRegex(prefix)}`\n : \"\"\n }${escapeRegex(str)}`,\n flags\n );\n}\n\n/**\n * Adds the virtual module prefix to the given ID.\n *\n * @param id - The ID to add the virtual module prefix to.\n * @returns The ID with the virtual module prefix added.\n */\nexport function addVirtualPrefix(id: string): string {\n return `${VIRTUAL_MODULE_PREFIX}${id}`;\n}\n\n/**\n * Removes the virtual module prefix from the given ID, if it exists.\n *\n * @param id - The ID to remove the virtual module prefix from.\n * @returns The ID without the virtual module prefix.\n */\nexport function removeVirtualPrefix(id: string): string {\n return id.replace(VIRTUAL_MODULE_PREFIX_REGEX, \"\");\n}\n\n/**\n * Checks if the given ID is a virtual module by checking if it starts with the virtual module prefix.\n *\n * @param id - The ID to check.\n * @returns True if the ID is a virtual module, false otherwise.\n */\nexport function isVirtualModule(id: string): boolean {\n return id.startsWith(VIRTUAL_MODULE_PREFIX);\n}\n\n/**\n * Creates a regular expression that matches the given ID with the virtual module prefix.\n *\n * @param id - The ID to create a regular expression for.\n * @returns A regular expression that matches the given ID with the virtual module prefix.\n */\nexport function createVirtualPrefixRegex(id: string): RegExp {\n return prefixRegex(removeVirtualPrefix(id), {\n prefix: VIRTUAL_MODULE_PREFIX,\n isPrefixOptional: true\n });\n}\n"],"mappings":";AAkBA,MAAM,eAAe;AACrB,SAAS,YAAY,KAAqB;AACxC,QAAO,IAAI,QAAQ,cAAc,OAAO;;AAG1C,MAAa,wBAAwB;AACrC,MAAa,8BAA8B,YAAY,KAAK;;;;;;;;;;;;;;;;;;;;AAsC5D,SAAgB,YACd,KACA,UAA8B,EAAE,EACxB;CACR,MAAM,EAAE,OAAO,QAAQ,mBAAmB,UAAU;AAEpD,QAAO,IAAI,OACT,IACE,SACI,mBACE,IAAI,YAAY,OAAO,CAAC,MACxB,GAAG,YAAY,OAAO,KACxB,KACH,YAAY,IAAI,IACnB,MACD;;;;;;;;AASH,SAAgB,iBAAiB,IAAoB;AACnD,QAAO,UAA2B;;;;;;;;AASpC,SAAgB,oBAAoB,IAAoB;AACtD,QAAO,GAAG,QAAQ,6BAA6B,GAAG;;;;;;;;AASpD,SAAgB,gBAAgB,IAAqB;AACnD,QAAO,GAAG,gBAAiC;;;;;;;;AAS7C,SAAgB,yBAAyB,IAAoB;AAC3D,QAAO,YAAY,oBAAoB,GAAG,EAAE;EAC1C;EACA,kBAAkB;EACnB,CAAC"}
@@ -0,0 +1,232 @@
1
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
+ let _stryke_capnp = require("@stryke/capnp");
3
+ _stryke_capnp = require_runtime.__toESM(_stryke_capnp, 1);
4
+
5
+ //#region schemas/fs.ts
6
+ const _capnpFileId = BigInt("0xa56c61324b9d6e49");
7
+ var FileMetadata_KeyValuePair = class extends _stryke_capnp.Struct {
8
+ static _capnp = {
9
+ displayName: "KeyValuePair",
10
+ id: "eabb26cf58b2a14c",
11
+ size: new _stryke_capnp.ObjectSize(0, 2)
12
+ };
13
+ get key() {
14
+ return _stryke_capnp.utils.getText(0, this);
15
+ }
16
+ set key(value) {
17
+ _stryke_capnp.utils.setText(0, value, this);
18
+ }
19
+ get value() {
20
+ return _stryke_capnp.utils.getText(1, this);
21
+ }
22
+ set value(value) {
23
+ _stryke_capnp.utils.setText(1, value, this);
24
+ }
25
+ toString() {
26
+ return "FileMetadata_KeyValuePair_" + super.toString();
27
+ }
28
+ };
29
+ /**
30
+ * The identifier for the file data.
31
+ *
32
+ */
33
+ var FileMetadata = class FileMetadata extends _stryke_capnp.Struct {
34
+ static KeyValuePair = FileMetadata_KeyValuePair;
35
+ static _capnp = {
36
+ displayName: "FileMetadata",
37
+ id: "8e2cab5d7e28c7b3",
38
+ size: new _stryke_capnp.ObjectSize(8, 3),
39
+ defaultType: "normal"
40
+ };
41
+ static _Properties;
42
+ /**
43
+ * The type of the file.
44
+ *
45
+ */
46
+ get id() {
47
+ return _stryke_capnp.utils.getText(0, this);
48
+ }
49
+ set id(value) {
50
+ _stryke_capnp.utils.setText(0, value, this);
51
+ }
52
+ /**
53
+ * The timestamp representing the file's creation date.
54
+ *
55
+ */
56
+ get type() {
57
+ return _stryke_capnp.utils.getText(1, this, FileMetadata._capnp.defaultType);
58
+ }
59
+ set type(value) {
60
+ _stryke_capnp.utils.setText(1, value, this);
61
+ }
62
+ /**
63
+ * Additional metadata associated with the file.
64
+ *
65
+ */
66
+ get timestamp() {
67
+ return _stryke_capnp.utils.getUint32(0, this);
68
+ }
69
+ set timestamp(value) {
70
+ _stryke_capnp.utils.setUint32(0, value, this);
71
+ }
72
+ _adoptProperties(value) {
73
+ _stryke_capnp.utils.adopt(value, _stryke_capnp.utils.getPointer(2, this));
74
+ }
75
+ _disownProperties() {
76
+ return _stryke_capnp.utils.disown(this.properties);
77
+ }
78
+ get properties() {
79
+ return _stryke_capnp.utils.getList(2, FileMetadata._Properties, this);
80
+ }
81
+ _hasProperties() {
82
+ return !_stryke_capnp.utils.isNull(_stryke_capnp.utils.getPointer(2, this));
83
+ }
84
+ _initProperties(length) {
85
+ return _stryke_capnp.utils.initList(2, FileMetadata._Properties, length, this);
86
+ }
87
+ set properties(value) {
88
+ _stryke_capnp.utils.copyFrom(value, _stryke_capnp.utils.getPointer(2, this));
89
+ }
90
+ toString() {
91
+ return "FileMetadata_" + super.toString();
92
+ }
93
+ };
94
+ /**
95
+ * An identifier for the file.
96
+ *
97
+ */
98
+ var FileId = class extends _stryke_capnp.Struct {
99
+ static _capnp = {
100
+ displayName: "FileId",
101
+ id: "990d6a471072f997",
102
+ size: new _stryke_capnp.ObjectSize(0, 2)
103
+ };
104
+ /**
105
+ * A virtual (or actual) path to the file in the file system.
106
+ *
107
+ */
108
+ get id() {
109
+ return _stryke_capnp.utils.getText(0, this);
110
+ }
111
+ set id(value) {
112
+ _stryke_capnp.utils.setText(0, value, this);
113
+ }
114
+ get path() {
115
+ return _stryke_capnp.utils.getText(1, this);
116
+ }
117
+ set path(value) {
118
+ _stryke_capnp.utils.setText(1, value, this);
119
+ }
120
+ toString() {
121
+ return "FileId_" + super.toString();
122
+ }
123
+ };
124
+ /**
125
+ * An identifier for the file.
126
+ *
127
+ */
128
+ var FileStorage = class extends _stryke_capnp.Struct {
129
+ static _capnp = {
130
+ displayName: "FileStorage",
131
+ id: "9dca66ac858c9ebe",
132
+ size: new _stryke_capnp.ObjectSize(0, 2)
133
+ };
134
+ /**
135
+ * A virtual (or actual) path to the file in the file system.
136
+ *
137
+ */
138
+ get path() {
139
+ return _stryke_capnp.utils.getText(0, this);
140
+ }
141
+ set path(value) {
142
+ _stryke_capnp.utils.setText(0, value, this);
143
+ }
144
+ get code() {
145
+ return _stryke_capnp.utils.getText(1, this);
146
+ }
147
+ set code(value) {
148
+ _stryke_capnp.utils.setText(1, value, this);
149
+ }
150
+ toString() {
151
+ return "FileStorage_" + super.toString();
152
+ }
153
+ };
154
+ var FileSystem = class FileSystem extends _stryke_capnp.Struct {
155
+ static _capnp = {
156
+ displayName: "FileSystem",
157
+ id: "ae0c23d43e56abcf",
158
+ size: new _stryke_capnp.ObjectSize(0, 3)
159
+ };
160
+ static _Ids;
161
+ static _Storage;
162
+ static _Metadata;
163
+ _adoptIds(value) {
164
+ _stryke_capnp.utils.adopt(value, _stryke_capnp.utils.getPointer(0, this));
165
+ }
166
+ _disownIds() {
167
+ return _stryke_capnp.utils.disown(this.ids);
168
+ }
169
+ get ids() {
170
+ return _stryke_capnp.utils.getList(0, FileSystem._Ids, this);
171
+ }
172
+ _hasIds() {
173
+ return !_stryke_capnp.utils.isNull(_stryke_capnp.utils.getPointer(0, this));
174
+ }
175
+ _initIds(length) {
176
+ return _stryke_capnp.utils.initList(0, FileSystem._Ids, length, this);
177
+ }
178
+ set ids(value) {
179
+ _stryke_capnp.utils.copyFrom(value, _stryke_capnp.utils.getPointer(0, this));
180
+ }
181
+ _adoptStorage(value) {
182
+ _stryke_capnp.utils.adopt(value, _stryke_capnp.utils.getPointer(1, this));
183
+ }
184
+ _disownStorage() {
185
+ return _stryke_capnp.utils.disown(this.storage);
186
+ }
187
+ get storage() {
188
+ return _stryke_capnp.utils.getList(1, FileSystem._Storage, this);
189
+ }
190
+ _hasStorage() {
191
+ return !_stryke_capnp.utils.isNull(_stryke_capnp.utils.getPointer(1, this));
192
+ }
193
+ _initStorage(length) {
194
+ return _stryke_capnp.utils.initList(1, FileSystem._Storage, length, this);
195
+ }
196
+ set storage(value) {
197
+ _stryke_capnp.utils.copyFrom(value, _stryke_capnp.utils.getPointer(1, this));
198
+ }
199
+ _adoptMetadata(value) {
200
+ _stryke_capnp.utils.adopt(value, _stryke_capnp.utils.getPointer(2, this));
201
+ }
202
+ _disownMetadata() {
203
+ return _stryke_capnp.utils.disown(this.metadata);
204
+ }
205
+ get metadata() {
206
+ return _stryke_capnp.utils.getList(2, FileSystem._Metadata, this);
207
+ }
208
+ _hasMetadata() {
209
+ return !_stryke_capnp.utils.isNull(_stryke_capnp.utils.getPointer(2, this));
210
+ }
211
+ _initMetadata(length) {
212
+ return _stryke_capnp.utils.initList(2, FileSystem._Metadata, length, this);
213
+ }
214
+ set metadata(value) {
215
+ _stryke_capnp.utils.copyFrom(value, _stryke_capnp.utils.getPointer(2, this));
216
+ }
217
+ toString() {
218
+ return "FileSystem_" + super.toString();
219
+ }
220
+ };
221
+ FileMetadata._Properties = _stryke_capnp.CompositeList(FileMetadata_KeyValuePair);
222
+ FileSystem._Ids = _stryke_capnp.CompositeList(FileId);
223
+ FileSystem._Storage = _stryke_capnp.CompositeList(FileStorage);
224
+ FileSystem._Metadata = _stryke_capnp.CompositeList(FileMetadata);
225
+
226
+ //#endregion
227
+ exports.FileId = FileId;
228
+ exports.FileMetadata = FileMetadata;
229
+ exports.FileMetadata_KeyValuePair = FileMetadata_KeyValuePair;
230
+ exports.FileStorage = FileStorage;
231
+ exports.FileSystem = FileSystem;
232
+ exports._capnpFileId = _capnpFileId;