@powerlines/core 0.2.22 → 0.3.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 (161) hide show
  1. package/dist/_virtual/{rolldown_runtime.cjs → _rolldown/runtime.cjs} +1 -1
  2. package/dist/constants/commands.d.cts.map +1 -1
  3. package/dist/constants/commands.d.mts.map +1 -1
  4. package/dist/constants/environments.d.cts.map +1 -1
  5. package/dist/constants/environments.d.mts.map +1 -1
  6. package/dist/constants/fs.d.cts.map +1 -1
  7. package/dist/constants/fs.d.mts.map +1 -1
  8. package/dist/constants/hooks.d.cts.map +1 -1
  9. package/dist/constants/hooks.d.mts.map +1 -1
  10. package/dist/constants/index.cjs +1 -0
  11. package/dist/constants/meta.d.cts.map +1 -1
  12. package/dist/constants/meta.d.mts.map +1 -1
  13. package/dist/constants/plugin.d.cts.map +1 -1
  14. package/dist/constants/plugin.d.mts.map +1 -1
  15. package/dist/index.cjs +1 -0
  16. package/dist/index.d.mts +0 -2
  17. package/dist/lib/config.cjs +18 -17
  18. package/dist/lib/config.d.cts.map +1 -1
  19. package/dist/lib/config.d.mts.map +1 -1
  20. package/dist/lib/config.mjs +3 -3
  21. package/dist/lib/config.mjs.map +1 -1
  22. package/dist/lib/entry.cjs +28 -27
  23. package/dist/lib/entry.d.cts.map +1 -1
  24. package/dist/lib/entry.d.mts +0 -1
  25. package/dist/lib/entry.d.mts.map +1 -1
  26. package/dist/lib/entry.mjs.map +1 -1
  27. package/dist/lib/index.cjs +1 -0
  28. package/dist/lib/index.d.mts +0 -2
  29. package/dist/lib/logger.cjs +14 -13
  30. package/dist/lib/logger.d.cts.map +1 -1
  31. package/dist/lib/logger.d.mts +0 -1
  32. package/dist/lib/logger.d.mts.map +1 -1
  33. package/dist/lib/unplugin/helpers.cjs +4 -3
  34. package/dist/lib/unplugin/helpers.d.cts +0 -1
  35. package/dist/lib/unplugin/helpers.d.cts.map +1 -1
  36. package/dist/lib/unplugin/helpers.d.mts +0 -1
  37. package/dist/lib/unplugin/helpers.d.mts.map +1 -1
  38. package/dist/lib/unplugin/helpers.mjs +2 -2
  39. package/dist/lib/unplugin/helpers.mjs.map +1 -1
  40. package/dist/lib/unplugin/index.cjs +1 -0
  41. package/dist/lib/unplugin/module-resolution.cjs +11 -10
  42. package/dist/lib/unplugin/module-resolution.d.cts.map +1 -1
  43. package/dist/lib/unplugin/module-resolution.d.mts.map +1 -1
  44. package/dist/lib/unplugin/plugin.cjs +14 -13
  45. package/dist/lib/unplugin/plugin.d.cts.map +1 -1
  46. package/dist/lib/unplugin/plugin.d.mts.map +1 -1
  47. package/dist/lib/unplugin/plugin.mjs.map +1 -1
  48. package/dist/lib/utilities/file-header.cjs +5 -4
  49. package/dist/lib/utilities/file-header.d.cts.map +1 -1
  50. package/dist/lib/utilities/file-header.d.mts.map +1 -1
  51. package/dist/lib/utilities/format.cjs +8 -7
  52. package/dist/lib/utilities/format.d.cts +0 -1
  53. package/dist/lib/utilities/format.d.cts.map +1 -1
  54. package/dist/lib/utilities/format.d.mts +0 -1
  55. package/dist/lib/utilities/format.d.mts.map +1 -1
  56. package/dist/lib/utilities/index.cjs +1 -0
  57. package/dist/lib/utilities/source-file.cjs +10 -9
  58. package/dist/lib/utilities/source-file.d.cts +0 -1
  59. package/dist/lib/utilities/source-file.d.cts.map +1 -1
  60. package/dist/lib/utilities/source-file.d.mts +0 -1
  61. package/dist/lib/utilities/source-file.d.mts.map +1 -1
  62. package/dist/lib/utilities/source-map.cjs +3 -2
  63. package/dist/lib/utilities/source-map.d.cts +0 -1
  64. package/dist/lib/utilities/source-map.d.cts.map +1 -1
  65. package/dist/lib/utilities/source-map.d.mts +0 -1
  66. package/dist/lib/utilities/source-map.d.mts.map +1 -1
  67. package/dist/lib/utilities/write-file.cjs +7 -6
  68. package/dist/lib/utilities/write-file.d.cts +0 -1
  69. package/dist/lib/utilities/write-file.d.cts.map +1 -1
  70. package/dist/lib/utilities/write-file.d.mts +0 -1
  71. package/dist/lib/utilities/write-file.d.mts.map +1 -1
  72. package/dist/plugin-base.cjs +8 -9
  73. package/dist/plugin-base.d.cts.map +1 -1
  74. package/dist/plugin-base.d.mts.map +1 -1
  75. package/dist/plugin-base.mjs +1 -2
  76. package/dist/plugin-base.mjs.map +1 -1
  77. package/dist/plugin-utils/build-helpers.cjs +12 -11
  78. package/dist/plugin-utils/build-helpers.d.cts.map +1 -1
  79. package/dist/plugin-utils/build-helpers.d.mts.map +1 -1
  80. package/dist/plugin-utils/combine-plugins.cjs +23 -0
  81. package/dist/plugin-utils/combine-plugins.d.cts +18 -0
  82. package/dist/plugin-utils/combine-plugins.d.cts.map +1 -0
  83. package/dist/plugin-utils/combine-plugins.d.mts +18 -0
  84. package/dist/plugin-utils/combine-plugins.d.mts.map +1 -0
  85. package/dist/plugin-utils/combine-plugins.mjs +22 -0
  86. package/dist/plugin-utils/combine-plugins.mjs.map +1 -0
  87. package/dist/plugin-utils/context-helpers.cjs +18 -17
  88. package/dist/plugin-utils/context-helpers.d.cts +0 -1
  89. package/dist/plugin-utils/context-helpers.d.cts.map +1 -1
  90. package/dist/plugin-utils/context-helpers.d.mts +0 -1
  91. package/dist/plugin-utils/context-helpers.d.mts.map +1 -1
  92. package/dist/plugin-utils/context-helpers.mjs.map +1 -1
  93. package/dist/plugin-utils/extend.cjs +12 -11
  94. package/dist/plugin-utils/extend.d.cts +0 -1
  95. package/dist/plugin-utils/extend.d.cts.map +1 -1
  96. package/dist/plugin-utils/extend.d.mts +0 -1
  97. package/dist/plugin-utils/extend.d.mts.map +1 -1
  98. package/dist/plugin-utils/format-package-json.cjs +6 -5
  99. package/dist/plugin-utils/format-package-json.d.cts +0 -1
  100. package/dist/plugin-utils/format-package-json.d.cts.map +1 -1
  101. package/dist/plugin-utils/format-package-json.d.mts +0 -1
  102. package/dist/plugin-utils/format-package-json.d.mts.map +1 -1
  103. package/dist/plugin-utils/get-config-path.cjs +35 -34
  104. package/dist/plugin-utils/get-config-path.d.cts +0 -1
  105. package/dist/plugin-utils/get-config-path.d.cts.map +1 -1
  106. package/dist/plugin-utils/get-config-path.d.mts +0 -1
  107. package/dist/plugin-utils/get-config-path.d.mts.map +1 -1
  108. package/dist/plugin-utils/helpers.cjs +15 -14
  109. package/dist/plugin-utils/helpers.d.cts +10 -11
  110. package/dist/plugin-utils/helpers.d.cts.map +1 -1
  111. package/dist/plugin-utils/helpers.d.mts +10 -11
  112. package/dist/plugin-utils/helpers.d.mts.map +1 -1
  113. package/dist/plugin-utils/helpers.mjs.map +1 -1
  114. package/dist/plugin-utils/index.cjs +3 -0
  115. package/dist/plugin-utils/index.d.cts +2 -1
  116. package/dist/plugin-utils/index.d.mts +2 -1
  117. package/dist/plugin-utils/index.mjs +2 -1
  118. package/dist/plugin-utils/merge.cjs +7 -6
  119. package/dist/plugin-utils/merge.d.cts.map +1 -1
  120. package/dist/plugin-utils/merge.d.mts +0 -2
  121. package/dist/plugin-utils/merge.d.mts.map +1 -1
  122. package/dist/plugin-utils/merge.mjs +2 -2
  123. package/dist/plugin-utils/merge.mjs.map +1 -1
  124. package/dist/plugin-utils/modules.cjs +1 -0
  125. package/dist/plugin-utils/modules.d.cts +0 -1
  126. package/dist/plugin-utils/modules.d.cts.map +1 -1
  127. package/dist/plugin-utils/modules.d.mts +0 -1
  128. package/dist/plugin-utils/modules.d.mts.map +1 -1
  129. package/dist/plugin-utils/modules.mjs.map +1 -1
  130. package/dist/plugin-utils/paths.cjs +5 -4
  131. package/dist/plugin-utils/paths.d.cts +0 -1
  132. package/dist/plugin-utils/paths.d.cts.map +1 -1
  133. package/dist/plugin-utils/paths.d.mts +0 -1
  134. package/dist/plugin-utils/paths.d.mts.map +1 -1
  135. package/dist/types/_internal.d.cts +0 -1
  136. package/dist/types/_internal.d.cts.map +1 -1
  137. package/dist/types/_internal.d.mts +0 -1
  138. package/dist/types/_internal.d.mts.map +1 -1
  139. package/dist/types/api.d.cts +0 -1
  140. package/dist/types/api.d.cts.map +1 -1
  141. package/dist/types/api.d.mts +0 -1
  142. package/dist/types/api.d.mts.map +1 -1
  143. package/dist/types/commands.d.cts.map +1 -1
  144. package/dist/types/commands.d.mts.map +1 -1
  145. package/dist/types/config.d.cts.map +1 -1
  146. package/dist/types/config.d.mts.map +1 -1
  147. package/dist/types/context.d.cts.map +1 -1
  148. package/dist/types/context.d.mts.map +1 -1
  149. package/dist/types/fs.d.cts.map +1 -1
  150. package/dist/types/fs.d.mts.map +1 -1
  151. package/dist/types/hooks.d.cts +10 -10
  152. package/dist/types/hooks.d.cts.map +1 -1
  153. package/dist/types/hooks.d.mts +10 -10
  154. package/dist/types/hooks.d.mts.map +1 -1
  155. package/dist/types/plugin.d.cts.map +1 -1
  156. package/dist/types/plugin.d.mts.map +1 -1
  157. package/dist/types/tsconfig.d.cts.map +1 -1
  158. package/dist/types/tsconfig.d.mts.map +1 -1
  159. package/dist/types/unplugin.d.cts.map +1 -1
  160. package/dist/types/unplugin.d.mts.map +1 -1
  161. package/package.json +7 -5
@@ -1,9 +1,9 @@
1
- Object.defineProperty(exports, '__esModule', { value: true });
2
- const require_rolldown_runtime = require('./_virtual/rolldown_runtime.cjs');
1
+ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: 'Module' } });
2
+ const require_runtime = require('./_virtual/_rolldown/runtime.cjs');
3
3
  const require_plugin_utils_format_package_json = require('./plugin-utils/format-package-json.cjs');
4
- let __stryke_path_append = require("@stryke/path/append");
5
- let __stryke_path_replace = require("@stryke/path/replace");
6
- let __stryke_path_join = require("@stryke/path/join");
4
+ let _stryke_path_append = require("@stryke/path/append");
5
+ let _stryke_path_replace = require("@stryke/path/replace");
6
+ let _stryke_path_join = require("@stryke/path/join");
7
7
  let tsdown = require("tsdown");
8
8
 
9
9
  //#region src/plugin-base.ts
@@ -54,8 +54,8 @@ const plugin = (options = {}) => {
54
54
  async build() {
55
55
  await (0, tsdown.build)({
56
56
  name: this.config.name,
57
- cwd: (0, __stryke_path_append.appendPath)(this.config.root, this.workspaceConfig.workspaceRoot),
58
- entry: this.entry.filter((entry) => entry?.file).length > 0 ? Object.fromEntries(this.entry.filter((entry) => entry?.file).map((entry) => [entry.output || (0, __stryke_path_replace.replaceExtension)((0, __stryke_path_replace.replacePath)((0, __stryke_path_replace.replacePath)(entry.file, (0, __stryke_path_join.joinPaths)(this.config.root, "src")), this.entryPath)), entry.file])) : [(0, __stryke_path_join.joinPaths)(this.workspaceConfig.workspaceRoot, this.config.root, "src", "**/*.ts"), (0, __stryke_path_join.joinPaths)(this.workspaceConfig.workspaceRoot, this.config.root, "src", "**/*.tsx")],
57
+ cwd: (0, _stryke_path_append.appendPath)(this.config.root, this.workspaceConfig.workspaceRoot),
58
+ entry: this.entry.filter((entry) => entry?.file).length > 0 ? Object.fromEntries(this.entry.filter((entry) => entry?.file).map((entry) => [entry.output || (0, _stryke_path_replace.replaceExtension)((0, _stryke_path_replace.replacePath)((0, _stryke_path_replace.replacePath)(entry.file, (0, _stryke_path_join.joinPaths)(this.config.root, "src")), this.entryPath)), entry.file])) : [(0, _stryke_path_join.joinPaths)(this.workspaceConfig.workspaceRoot, this.config.root, "src", "**/*.ts"), (0, _stryke_path_join.joinPaths)(this.workspaceConfig.workspaceRoot, this.config.root, "src", "**/*.tsx")],
59
59
  platform: this.config.platform,
60
60
  tsconfig: this.tsconfig.tsconfigFilePath,
61
61
  outDir: this.config.output.buildPath,
@@ -65,8 +65,7 @@ const plugin = (options = {}) => {
65
65
  }
66
66
  };
67
67
  };
68
- var plugin_base_default = plugin;
69
68
 
70
69
  //#endregion
71
- exports.default = plugin_base_default;
70
+ exports.default = plugin;
72
71
  exports.plugin = plugin;
@@ -1 +1 @@
1
- {"version":3,"file":"plugin-base.d.cts","names":[],"sources":["../src/plugin-base.ts"],"sourcesContent":[],"mappings":";;;;;;UA2BiB,iBAAA;WACN,QAAQ;AADnB;AAIY,KAAA,oBAAA,GAAuB,YAAA,GAAA;EAIvB,MAAA,EAHF,iBAGE;CAA2B;AACpB,KADP,wBAAA,GAA2B,cACpB,GAAA;EAAT,MAAA,EAAA,QAAA,CAAS,iBAAT,CAAA;CAAQ;AAGN,KAAA,iBAAiB,CAAA,wBACH,wBADG,GACwB,wBADxB,CAAA,GAEzB,aAFyB,CAEX,eAFW,CAAA;;;;AAEzB,cAKS,MALT,EAAA,CAAA,iBAKoC,iBALpC,GAKwD,iBALxD,CAAA,CAAA,OAAA,CAAA,EAMO,iBANP,EAAA,GAOD,MAPC,CAOM,QAPN,CAAA;AAKS,oCAmFZ,GAAA,EAAA;AAnFuC,uCAAA,GAAA,EAAA;AAAoB,2CAAA,GAAA,EAAA;AACjD,oCAAA,GAAA,EAAA"}
1
+ {"version":3,"file":"plugin-base.d.cts","names":[],"sources":["../src/plugin-base.ts"],"mappings":";;;;;;UA2BiB,iBAAA;EACf,MAAA,GAAS,OAAA,CAAQ,UAAA;AAAA;AAAA,KAGP,oBAAA,GAAuB,YAAA;EACjC,MAAA,EAAQ,iBAAA;AAAA;AAAA,KAGE,wBAAA,GAA2B,cAAA;EACrC,MAAA,EAAQ,QAAA,CAAS,iBAAA;AAAA;AAAA,KAGP,iBAAA,yBACc,wBAAA,GAA2B,wBAAA,IACjD,aAAA,CAAc,eAAA;;AAVlB;;cAea,MAAA,oBAA2B,iBAAA,GAAoB,iBAAA,EAC1D,OAAA,GAAS,iBAAA,KACR,MAAA,CAAO,QAAA;AAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"plugin-base.d.mts","names":[],"sources":["../src/plugin-base.ts"],"sourcesContent":[],"mappings":";;;;;;UA2BiB,iBAAA;WACN,QAAQ;AADnB;AAIY,KAAA,oBAAA,GAAuB,YAAA,GAAA;EAIvB,MAAA,EAHF,iBAGE;CAA2B;AACpB,KADP,wBAAA,GAA2B,cACpB,GAAA;EAAT,MAAA,EAAA,QAAA,CAAS,iBAAT,CAAA;CAAQ;AAGN,KAAA,iBAAiB,CAAA,wBACH,wBADG,GACwB,wBADxB,CAAA,GAEzB,aAFyB,CAEX,eAFW,CAAA;;;;AAEzB,cAKS,MALT,EAAA,CAAA,iBAKoC,iBALpC,GAKwD,iBALxD,CAAA,CAAA,OAAA,CAAA,EAMO,iBANP,EAAA,GAOD,MAPC,CAOM,QAPN,CAAA;AAKS,oCAmFZ,GAAA,EAAA;AAnFuC,uCAAA,GAAA,EAAA;AAAoB,2CAAA,GAAA,EAAA;AACjD,oCAAA,GAAA,EAAA"}
1
+ {"version":3,"file":"plugin-base.d.mts","names":[],"sources":["../src/plugin-base.ts"],"mappings":";;;;;;UA2BiB,iBAAA;EACf,MAAA,GAAS,OAAA,CAAQ,UAAA;AAAA;AAAA,KAGP,oBAAA,GAAuB,YAAA;EACjC,MAAA,EAAQ,iBAAA;AAAA;AAAA,KAGE,wBAAA,GAA2B,cAAA;EACrC,MAAA,EAAQ,QAAA,CAAS,iBAAA;AAAA;AAAA,KAGP,iBAAA,yBACc,wBAAA,GAA2B,wBAAA,IACjD,aAAA,CAAc,eAAA;;AAVlB;;cAea,MAAA,oBAA2B,iBAAA,GAAoB,iBAAA,EAC1D,OAAA,GAAS,iBAAA,KACR,MAAA,CAAO,QAAA;AAAA"}
@@ -63,8 +63,7 @@ const plugin = (options = {}) => {
63
63
  }
64
64
  };
65
65
  };
66
- var plugin_base_default = plugin;
67
66
 
68
67
  //#endregion
69
- export { plugin_base_default as default, plugin };
68
+ export { plugin as default, plugin };
70
69
  //# sourceMappingURL=plugin-base.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"plugin-base.mjs","names":[],"sources":["../src/plugin-base.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 { appendPath } from \"@stryke/path/append\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { replaceExtension, replacePath } from \"@stryke/path/replace\";\nimport { build, UserConfig as BuildOptions } from \"tsdown\";\nimport { formatPackageJson } from \"./plugin-utils/format-package-json\";\nimport { ResolvedConfig, UserConfig } from \"./types/config\";\nimport { PluginContext } from \"./types/context\";\nimport { Plugin } from \"./types/plugin\";\n\nexport interface BasePluginOptions {\n tsdown?: Partial<BuildOptions>;\n}\n\nexport type BasePluginUserConfig = UserConfig & {\n tsdown: BasePluginOptions;\n};\n\nexport type BasePluginResolvedConfig = ResolvedConfig & {\n tsdown: Required<BasePluginOptions>;\n};\n\nexport type BasePluginContext<\n TResolvedConfig extends BasePluginResolvedConfig = BasePluginResolvedConfig\n> = PluginContext<TResolvedConfig>;\n\n/**\n * A Powerlines plugin to assist in developing other Powerlines plugins.\n */\nexport const plugin = <TContext extends BasePluginContext = BasePluginContext>(\n options: BasePluginOptions = {}\n): Plugin<TContext> => {\n return {\n name: \"base\",\n config() {\n return {\n projectType: \"library\",\n input: [\"src/index.ts\", \"src/types/*.ts\", \"src/helpers/*.ts\"],\n output: {\n format: [\"cjs\", \"esm\"],\n dts: false\n },\n platform: \"node\",\n tsdown: {\n format: [\"cjs\", \"esm\"],\n logLevel: \"silent\",\n target: \"node22\",\n cjsDefault: true,\n treeshake: true,\n exports: {\n all: true\n },\n fixedExtension: true,\n nodeProtocol: true,\n minify: false,\n dts: true,\n shims: true,\n outDir: \"dist\",\n clean: true,\n external: [\"powerlines\", /^powerlines\\/.*$/, /^@powerlines\\//],\n skipNodeModulesBundle: true,\n unbundle: false,\n ...options.tsdown\n }\n };\n },\n async build() {\n await build({\n name: this.config.name,\n cwd: appendPath(this.config.root, this.workspaceConfig.workspaceRoot),\n entry:\n this.entry.filter(entry => entry?.file).length > 0\n ? Object.fromEntries(\n this.entry\n .filter(entry => entry?.file)\n .map(entry => [\n entry.output ||\n replaceExtension(\n replacePath(\n replacePath(\n entry.file,\n joinPaths(this.config.root, \"src\")\n ),\n this.entryPath\n )\n ),\n entry.file\n ])\n )\n : [\n joinPaths(\n this.workspaceConfig.workspaceRoot,\n this.config.root,\n \"src\",\n \"**/*.ts\"\n ),\n joinPaths(\n this.workspaceConfig.workspaceRoot,\n this.config.root,\n \"src\",\n \"**/*.tsx\"\n )\n ],\n platform: this.config.platform,\n tsconfig: this.tsconfig.tsconfigFilePath,\n outDir: this.config.output.buildPath,\n ...this.config.tsdown\n });\n\n await formatPackageJson(this);\n }\n };\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;AA8CA,MAAa,UACX,UAA6B,EAAE,KACV;AACrB,QAAO;EACL,MAAM;EACN,SAAS;AACP,UAAO;IACL,aAAa;IACb,OAAO;KAAC;KAAgB;KAAkB;KAAmB;IAC7D,QAAQ;KACN,QAAQ,CAAC,OAAO,MAAM;KACtB,KAAK;KACN;IACD,UAAU;IACV,QAAQ;KACN,QAAQ,CAAC,OAAO,MAAM;KACtB,UAAU;KACV,QAAQ;KACR,YAAY;KACZ,WAAW;KACX,SAAS,EACP,KAAK,MACN;KACD,gBAAgB;KAChB,cAAc;KACd,QAAQ;KACR,KAAK;KACL,OAAO;KACP,QAAQ;KACR,OAAO;KACP,UAAU;MAAC;MAAc;MAAoB;MAAiB;KAC9D,uBAAuB;KACvB,UAAU;KACV,GAAG,QAAQ;KACZ;IACF;;EAEH,MAAM,QAAQ;AACZ,SAAM,MAAM;IACV,MAAM,KAAK,OAAO;IAClB,KAAK,WAAW,KAAK,OAAO,MAAM,KAAK,gBAAgB,cAAc;IACrE,OACE,KAAK,MAAM,QAAO,UAAS,OAAO,KAAK,CAAC,SAAS,IAC7C,OAAO,YACL,KAAK,MACF,QAAO,UAAS,OAAO,KAAK,CAC5B,KAAI,UAAS,CACZ,MAAM,UACJ,iBACE,YACE,YACE,MAAM,MACN,UAAU,KAAK,OAAO,MAAM,MAAM,CACnC,EACD,KAAK,UACN,CACF,EACH,MAAM,KACP,CAAC,CACL,GACD,CACE,UACE,KAAK,gBAAgB,eACrB,KAAK,OAAO,MACZ,OACA,UACD,EACD,UACE,KAAK,gBAAgB,eACrB,KAAK,OAAO,MACZ,OACA,WACD,CACF;IACP,UAAU,KAAK,OAAO;IACtB,UAAU,KAAK,SAAS;IACxB,QAAQ,KAAK,OAAO,OAAO;IAC3B,GAAG,KAAK,OAAO;IAChB,CAAC;AAEF,SAAM,kBAAkB,KAAK;;EAEhC;;AAGH,0BAAe"}
1
+ {"version":3,"file":"plugin-base.mjs","names":[],"sources":["../src/plugin-base.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 { appendPath } from \"@stryke/path/append\";\nimport { joinPaths } from \"@stryke/path/join\";\nimport { replaceExtension, replacePath } from \"@stryke/path/replace\";\nimport { build, UserConfig as BuildOptions } from \"tsdown\";\nimport { formatPackageJson } from \"./plugin-utils/format-package-json\";\nimport { ResolvedConfig, UserConfig } from \"./types/config\";\nimport { PluginContext } from \"./types/context\";\nimport { Plugin } from \"./types/plugin\";\n\nexport interface BasePluginOptions {\n tsdown?: Partial<BuildOptions>;\n}\n\nexport type BasePluginUserConfig = UserConfig & {\n tsdown: BasePluginOptions;\n};\n\nexport type BasePluginResolvedConfig = ResolvedConfig & {\n tsdown: Required<BasePluginOptions>;\n};\n\nexport type BasePluginContext<\n TResolvedConfig extends BasePluginResolvedConfig = BasePluginResolvedConfig\n> = PluginContext<TResolvedConfig>;\n\n/**\n * A Powerlines plugin to assist in developing other Powerlines plugins.\n */\nexport const plugin = <TContext extends BasePluginContext = BasePluginContext>(\n options: BasePluginOptions = {}\n): Plugin<TContext> => {\n return {\n name: \"base\",\n config() {\n return {\n projectType: \"library\",\n input: [\"src/index.ts\", \"src/types/*.ts\", \"src/helpers/*.ts\"],\n output: {\n format: [\"cjs\", \"esm\"],\n dts: false\n },\n platform: \"node\",\n tsdown: {\n format: [\"cjs\", \"esm\"],\n logLevel: \"silent\",\n target: \"node22\",\n cjsDefault: true,\n treeshake: true,\n exports: {\n all: true\n },\n fixedExtension: true,\n nodeProtocol: true,\n minify: false,\n dts: true,\n shims: true,\n outDir: \"dist\",\n clean: true,\n external: [\"powerlines\", /^powerlines\\/.*$/, /^@powerlines\\//],\n skipNodeModulesBundle: true,\n unbundle: false,\n ...options.tsdown\n }\n };\n },\n async build() {\n await build({\n name: this.config.name,\n cwd: appendPath(this.config.root, this.workspaceConfig.workspaceRoot),\n entry:\n this.entry.filter(entry => entry?.file).length > 0\n ? Object.fromEntries(\n this.entry\n .filter(entry => entry?.file)\n .map(entry => [\n entry.output ||\n replaceExtension(\n replacePath(\n replacePath(\n entry.file,\n joinPaths(this.config.root, \"src\")\n ),\n this.entryPath\n )\n ),\n entry.file\n ])\n )\n : [\n joinPaths(\n this.workspaceConfig.workspaceRoot,\n this.config.root,\n \"src\",\n \"**/*.ts\"\n ),\n joinPaths(\n this.workspaceConfig.workspaceRoot,\n this.config.root,\n \"src\",\n \"**/*.tsx\"\n )\n ],\n platform: this.config.platform,\n tsconfig: this.tsconfig.tsconfigFilePath,\n outDir: this.config.output.buildPath,\n ...this.config.tsdown\n });\n\n await formatPackageJson(this);\n }\n };\n};\n\nexport default plugin;\n"],"mappings":";;;;;;;;;;AA8CA,MAAa,UACX,UAA6B,EAAE,KACV;AACrB,QAAO;EACL,MAAM;EACN,SAAS;AACP,UAAO;IACL,aAAa;IACb,OAAO;KAAC;KAAgB;KAAkB;KAAmB;IAC7D,QAAQ;KACN,QAAQ,CAAC,OAAO,MAAM;KACtB,KAAK;KACN;IACD,UAAU;IACV,QAAQ;KACN,QAAQ,CAAC,OAAO,MAAM;KACtB,UAAU;KACV,QAAQ;KACR,YAAY;KACZ,WAAW;KACX,SAAS,EACP,KAAK,MACN;KACD,gBAAgB;KAChB,cAAc;KACd,QAAQ;KACR,KAAK;KACL,OAAO;KACP,QAAQ;KACR,OAAO;KACP,UAAU;MAAC;MAAc;MAAoB;MAAiB;KAC9D,uBAAuB;KACvB,UAAU;KACV,GAAG,QAAQ;KACZ;IACF;;EAEH,MAAM,QAAQ;AACZ,SAAM,MAAM;IACV,MAAM,KAAK,OAAO;IAClB,KAAK,WAAW,KAAK,OAAO,MAAM,KAAK,gBAAgB,cAAc;IACrE,OACE,KAAK,MAAM,QAAO,UAAS,OAAO,KAAK,CAAC,SAAS,IAC7C,OAAO,YACL,KAAK,MACF,QAAO,UAAS,OAAO,KAAK,CAC5B,KAAI,UAAS,CACZ,MAAM,UACJ,iBACE,YACE,YACE,MAAM,MACN,UAAU,KAAK,OAAO,MAAM,MAAM,CACnC,EACD,KAAK,UACN,CACF,EACH,MAAM,KACP,CAAC,CACL,GACD,CACE,UACE,KAAK,gBAAgB,eACrB,KAAK,OAAO,MACZ,OACA,UACD,EACD,UACE,KAAK,gBAAgB,eACrB,KAAK,OAAO,MACZ,OACA,WACD,CACF;IACP,UAAU,KAAK,OAAO;IACtB,UAAU,KAAK,SAAS;IACxB,QAAQ,KAAK,OAAO,OAAO;IAC3B,GAAG,KAAK,OAAO;IAChB,CAAC;AAEF,SAAM,kBAAkB,KAAK;;EAEhC"}
@@ -1,8 +1,9 @@
1
- const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
- let __stryke_convert_to_array = require("@stryke/convert/to-array");
3
- let __stryke_helpers_get_unique = require("@stryke/helpers/get-unique");
4
- let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
5
- let __stryke_type_checks_is_regexp = require("@stryke/type-checks/is-regexp");
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
3
+ let _stryke_convert_to_array = require("@stryke/convert/to-array");
4
+ let _stryke_helpers_get_unique = require("@stryke/helpers/get-unique");
5
+ let _stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
6
+ let _stryke_type_checks_is_regexp = require("@stryke/type-checks/is-regexp");
6
7
 
7
8
  //#region src/plugin-utils/build-helpers.ts
8
9
  /**
@@ -12,13 +13,13 @@ let __stryke_type_checks_is_regexp = require("@stryke/type-checks/is-regexp");
12
13
  * @returns The dependency configuration.
13
14
  */
14
15
  function getDependencyConfig(context) {
15
- const noExternal = (0, __stryke_helpers_get_unique.getUnique)((0, __stryke_convert_to_array.toArray)(context.config.resolve.noExternal).concat(context.builtins));
16
- const external = (0, __stryke_helpers_get_unique.getUnique)((0, __stryke_convert_to_array.toArray)(context.config.resolve.external).reduce((ret, ext) => {
17
- if ((0, __stryke_type_checks_is_regexp.isRegExp)(ext)) {
18
- if (noExternal.some((noExt) => (0, __stryke_type_checks_is_regexp.isRegExp)(noExt) && noExt.source === ext.source)) return ret;
19
- const noExts = noExternal.filter((noExt) => (0, __stryke_type_checks_is_set_string.isSetString)(noExt) && ext.test(noExt));
16
+ const noExternal = (0, _stryke_helpers_get_unique.getUnique)((0, _stryke_convert_to_array.toArray)(context.config.resolve.noExternal).concat(context.builtins));
17
+ const external = (0, _stryke_helpers_get_unique.getUnique)((0, _stryke_convert_to_array.toArray)(context.config.resolve.external).reduce((ret, ext) => {
18
+ if ((0, _stryke_type_checks_is_regexp.isRegExp)(ext)) {
19
+ if (noExternal.some((noExt) => (0, _stryke_type_checks_is_regexp.isRegExp)(noExt) && noExt.source === ext.source)) return ret;
20
+ const noExts = noExternal.filter((noExt) => (0, _stryke_type_checks_is_set_string.isSetString)(noExt) && ext.test(noExt));
20
21
  if (noExts.length > 0) {
21
- ret.push(new RegExp(noExts.reduce((regex, noExt) => `(?!${(0, __stryke_type_checks_is_regexp.isRegExp)(noExt) ? noExt.source : `^${noExt}$`})${regex}`, `${ext.source.replace(/^\^@\?/, "^@").replace(/^@\?/, "@").replace(/\$$/, "").replace(/\.\*$/, "")}.*$`)));
22
+ ret.push(new RegExp(noExts.reduce((regex, noExt) => `(?!${(0, _stryke_type_checks_is_regexp.isRegExp)(noExt) ? noExt.source : `^${noExt}$`})${regex}`, `${ext.source.replace(/^\^@\?/, "^@").replace(/^@\?/, "@").replace(/\$$/, "").replace(/\.\*$/, "")}.*$`)));
22
23
  return ret;
23
24
  }
24
25
  }
@@ -1 +1 @@
1
- {"version":3,"file":"build-helpers.d.cts","names":[],"sources":["../../src/plugin-utils/build-helpers.ts"],"sourcesContent":[],"mappings":";;;;UAyBiB,yBAAA;YACL;EADK,UAAA,EAEH,aAFG,CAAA,YAAyB,CAAA;AAW1C;;;;;;;iBAAgB,mBAAA,UACL,UACR"}
1
+ {"version":3,"file":"build-helpers.d.cts","names":[],"sources":["../../src/plugin-utils/build-helpers.ts"],"mappings":";;;;UAyBiB,yBAAA;EACf,QAAA,EAAU,aAAA;EACV,UAAA,EAAY,aAAA;AAAA;;;;;;;iBASE,mBAAA,CACd,OAAA,EAAS,OAAA,GACR,yBAAA;AAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"build-helpers.d.mts","names":[],"sources":["../../src/plugin-utils/build-helpers.ts"],"sourcesContent":[],"mappings":";;;;UAyBiB,yBAAA;YACL;EADK,UAAA,EAEH,aAFG,CAAA,YAAyB,CAAA;AAW1C;;;;;;;iBAAgB,mBAAA,UACL,UACR"}
1
+ {"version":3,"file":"build-helpers.d.mts","names":[],"sources":["../../src/plugin-utils/build-helpers.ts"],"mappings":";;;;UAyBiB,yBAAA;EACf,QAAA,EAAU,aAAA;EACV,UAAA,EAAY,aAAA;AAAA;;;;;;;iBASE,mBAAA,CACd,OAAA,EAAS,OAAA,GACR,yBAAA;AAAA"}
@@ -0,0 +1,23 @@
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
3
+ let unplugin_combine = require("unplugin-combine");
4
+
5
+ //#region src/plugin-utils/combine-plugins.ts
6
+ /**
7
+ * Combines multiple plugins into a single plugin. This is useful for creating meta-plugins that encapsulate the functionality of multiple plugins, allowing users to easily include a set of related plugins with a single import.
8
+ *
9
+ * @param options - The options for combining plugins, including the name and the plugins to combine.
10
+ * @returns A single plugin that combines the functionality of the provided plugins.
11
+ */
12
+ function combinePlugins(options) {
13
+ const { name = "powerlines-combined ", plugins } = options;
14
+ return (0, unplugin_combine.createCombinePlugin)(() => {
15
+ return {
16
+ name,
17
+ plugins
18
+ };
19
+ });
20
+ }
21
+
22
+ //#endregion
23
+ exports.combinePlugins = combinePlugins;
@@ -0,0 +1,18 @@
1
+ import { OptionsPlugin, UnpluginCombineInstance } from "unplugin-combine";
2
+
3
+ //#region src/plugin-utils/combine-plugins.d.ts
4
+ interface CombinePluginsOptions {
5
+ name?: string;
6
+ plugins: OptionsPlugin[];
7
+ }
8
+ /**
9
+ * Combines multiple plugins into a single plugin. This is useful for creating meta-plugins that encapsulate the functionality of multiple plugins, allowing users to easily include a set of related plugins with a single import.
10
+ *
11
+ * @param options - The options for combining plugins, including the name and the plugins to combine.
12
+ * @returns A single plugin that combines the functionality of the provided plugins.
13
+ */
14
+ declare function combinePlugins(options: CombinePluginsOptions): UnpluginCombineInstance<any>;
15
+ declare type __ΩCombinePluginsOptions = any[];
16
+ //#endregion
17
+ export { CombinePluginsOptions, __ΩCombinePluginsOptions, combinePlugins };
18
+ //# sourceMappingURL=combine-plugins.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"combine-plugins.d.cts","names":[],"sources":["../../src/plugin-utils/combine-plugins.ts"],"mappings":";;;UAwBiB,qBAAA;EACf,IAAA;EACA,OAAA,EAAS,aAAA;AAAA;;;;;;;iBASK,cAAA,CACd,OAAA,EAAS,qBAAA,GACR,uBAAA;AAAA"}
@@ -0,0 +1,18 @@
1
+ import { OptionsPlugin, UnpluginCombineInstance } from "unplugin-combine";
2
+
3
+ //#region src/plugin-utils/combine-plugins.d.ts
4
+ interface CombinePluginsOptions {
5
+ name?: string;
6
+ plugins: OptionsPlugin[];
7
+ }
8
+ /**
9
+ * Combines multiple plugins into a single plugin. This is useful for creating meta-plugins that encapsulate the functionality of multiple plugins, allowing users to easily include a set of related plugins with a single import.
10
+ *
11
+ * @param options - The options for combining plugins, including the name and the plugins to combine.
12
+ * @returns A single plugin that combines the functionality of the provided plugins.
13
+ */
14
+ declare function combinePlugins(options: CombinePluginsOptions): UnpluginCombineInstance<any>;
15
+ declare type __ΩCombinePluginsOptions = any[];
16
+ //#endregion
17
+ export { CombinePluginsOptions, __ΩCombinePluginsOptions, combinePlugins };
18
+ //# sourceMappingURL=combine-plugins.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"combine-plugins.d.mts","names":[],"sources":["../../src/plugin-utils/combine-plugins.ts"],"mappings":";;;UAwBiB,qBAAA;EACf,IAAA;EACA,OAAA,EAAS,aAAA;AAAA;;;;;;;iBASK,cAAA,CACd,OAAA,EAAS,qBAAA,GACR,uBAAA;AAAA"}
@@ -0,0 +1,22 @@
1
+ import { createCombinePlugin } from "unplugin-combine";
2
+
3
+ //#region src/plugin-utils/combine-plugins.ts
4
+ /**
5
+ * Combines multiple plugins into a single plugin. This is useful for creating meta-plugins that encapsulate the functionality of multiple plugins, allowing users to easily include a set of related plugins with a single import.
6
+ *
7
+ * @param options - The options for combining plugins, including the name and the plugins to combine.
8
+ * @returns A single plugin that combines the functionality of the provided plugins.
9
+ */
10
+ function combinePlugins(options) {
11
+ const { name = "powerlines-combined ", plugins } = options;
12
+ return createCombinePlugin(() => {
13
+ return {
14
+ name,
15
+ plugins
16
+ };
17
+ });
18
+ }
19
+
20
+ //#endregion
21
+ export { combinePlugins };
22
+ //# sourceMappingURL=combine-plugins.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"combine-plugins.mjs","names":[],"sources":["../../src/plugin-utils/combine-plugins.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 {\n createCombinePlugin,\n OptionsPlugin,\n UnpluginCombineInstance\n} from \"unplugin-combine\";\n\nexport interface CombinePluginsOptions {\n name?: string;\n plugins: OptionsPlugin[];\n}\n\n/**\n * Combines multiple plugins into a single plugin. This is useful for creating meta-plugins that encapsulate the functionality of multiple plugins, allowing users to easily include a set of related plugins with a single import.\n *\n * @param options - The options for combining plugins, including the name and the plugins to combine.\n * @returns A single plugin that combines the functionality of the provided plugins.\n */\nexport function combinePlugins(\n options: CombinePluginsOptions\n): UnpluginCombineInstance<any> {\n const { name = \"powerlines-combined \", plugins } = options;\n\n return createCombinePlugin(() => {\n return {\n name,\n plugins\n };\n });\n}\n"],"mappings":";;;;;;;;;AAmCA,SAAgB,eACd,SAC8B;CAC9B,MAAM,EAAE,OAAO,wBAAwB,YAAY;AAEnD,QAAO,0BAA0B;AAC/B,SAAO;GACL;GACA;GACD;GACD"}
@@ -1,6 +1,7 @@
1
- const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
2
- let __stryke_type_checks_is_set_object = require("@stryke/type-checks/is-set-object");
3
- let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
3
+ let _stryke_type_checks_is_set_object = require("@stryke/type-checks/is-set-object");
4
+ let _stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
4
5
 
5
6
  //#region src/plugin-utils/context-helpers.ts
6
7
  /**
@@ -11,22 +12,22 @@ let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-str
11
12
  */
12
13
  function getOrganizationName(context) {
13
14
  let result;
14
- if ((0, __stryke_type_checks_is_set_object.isSetObject)(context.workspaceConfig.organization)) result = context.workspaceConfig.organization.name;
15
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.organization)) result = context.workspaceConfig.organization;
15
+ if ((0, _stryke_type_checks_is_set_object.isSetObject)(context.workspaceConfig.organization)) result = context.workspaceConfig.organization.name;
16
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.organization)) result = context.workspaceConfig.organization;
16
17
  if (!result && Array.isArray(context.packageJson.maintainers) && context.packageJson.maintainers.length > 0) {
17
- if ((0, __stryke_type_checks_is_set_object.isSetObject)(context.packageJson.maintainers[0])) result = context.packageJson.maintainers[0].name;
18
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.maintainers[0])) result = context.packageJson.maintainers[0];
18
+ if ((0, _stryke_type_checks_is_set_object.isSetObject)(context.packageJson.maintainers[0])) result = context.packageJson.maintainers[0].name;
19
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.maintainers[0])) result = context.packageJson.maintainers[0];
19
20
  }
20
21
  if (!result && Array.isArray(context.packageJson.author) && context.packageJson.author.length > 0) {
21
- if ((0, __stryke_type_checks_is_set_object.isSetObject)(context.packageJson.author[0])) result = context.packageJson.author[0].name;
22
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.author[0])) result = context.packageJson.author[0];
22
+ if ((0, _stryke_type_checks_is_set_object.isSetObject)(context.packageJson.author[0])) result = context.packageJson.author[0].name;
23
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.author[0])) result = context.packageJson.author[0];
23
24
  }
24
25
  if (!result && Array.isArray(context.packageJson.contributors) && context.packageJson.contributors.length > 0) {
25
- if ((0, __stryke_type_checks_is_set_object.isSetObject)(context.packageJson.contributors[0])) result = context.packageJson.contributors[0].name;
26
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.contributors[0])) result = context.packageJson.contributors[0];
26
+ if ((0, _stryke_type_checks_is_set_object.isSetObject)(context.packageJson.contributors[0])) result = context.packageJson.contributors[0].name;
27
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.contributors[0])) result = context.packageJson.contributors[0];
27
28
  }
28
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.namespace)) result = context.packageJson.namespace.replace(/^@/, "");
29
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.name)) result = context.packageJson.name.replace(/^@/, "").replace(/\/.*$/, "");
29
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.namespace)) result = context.packageJson.namespace.replace(/^@/, "");
30
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.name)) result = context.packageJson.name.replace(/^@/, "").replace(/\/.*$/, "");
30
31
  return result;
31
32
  }
32
33
  /**
@@ -37,10 +38,10 @@ function getOrganizationName(context) {
37
38
  */
38
39
  function getWorkspaceName(context) {
39
40
  let result;
40
- if ((0, __stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.name)) result = context.workspaceConfig.name;
41
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.namespace)) result = context.workspaceConfig.namespace.replace(/^@/, "");
42
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.namespace)) result = context.packageJson.namespace.replace(/^@/, "");
43
- if (!result && (0, __stryke_type_checks_is_set_string.isSetString)(context.packageJson.name)) result = context.packageJson.name.replace(/^@/, "").replace(/\/.*$/, "");
41
+ if ((0, _stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.name)) result = context.workspaceConfig.name;
42
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.workspaceConfig.namespace)) result = context.workspaceConfig.namespace.replace(/^@/, "");
43
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.namespace)) result = context.packageJson.namespace.replace(/^@/, "");
44
+ if (!result && (0, _stryke_type_checks_is_set_string.isSetString)(context.packageJson.name)) result = context.packageJson.name.replace(/^@/, "").replace(/\/.*$/, "");
44
45
  return result;
45
46
  }
46
47
 
@@ -1,7 +1,6 @@
1
1
  import { UnresolvedContext } from "../types/context.cjs";
2
2
 
3
3
  //#region src/plugin-utils/context-helpers.d.ts
4
-
5
4
  /**
6
5
  * Get the organization name from the context
7
6
  *
@@ -1 +1 @@
1
- {"version":3,"file":"context-helpers.d.cts","names":[],"sources":["../../src/plugin-utils/context-helpers.ts"],"sourcesContent":[],"mappings":";;;;;;AA4BA;AAuEA;;;iBAvEgB,mBAAA,UACL;;;;;;;iBAsEK,gBAAA,UACL"}
1
+ {"version":3,"file":"context-helpers.d.cts","names":[],"sources":["../../src/plugin-utils/context-helpers.ts"],"mappings":";;;;;AA4BA;;;;iBAAgB,mBAAA,CACd,OAAA,EAAS,iBAAA;AAsEX;;;;;;AAAA,iBAAgB,gBAAA,CACd,OAAA,EAAS,iBAAA"}
@@ -1,7 +1,6 @@
1
1
  import { UnresolvedContext } from "../types/context.mjs";
2
2
 
3
3
  //#region src/plugin-utils/context-helpers.d.ts
4
-
5
4
  /**
6
5
  * Get the organization name from the context
7
6
  *
@@ -1 +1 @@
1
- {"version":3,"file":"context-helpers.d.mts","names":[],"sources":["../../src/plugin-utils/context-helpers.ts"],"sourcesContent":[],"mappings":";;;;;;AA4BA;AAuEA;;;iBAvEgB,mBAAA,UACL;;;;;;;iBAsEK,gBAAA,UACL"}
1
+ {"version":3,"file":"context-helpers.d.mts","names":[],"sources":["../../src/plugin-utils/context-helpers.ts"],"mappings":";;;;;AA4BA;;;;iBAAgB,mBAAA,CACd,OAAA,EAAS,iBAAA;AAsEX;;;;;;AAAA,iBAAgB,gBAAA,CACd,OAAA,EAAS,iBAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"context-helpers.mjs","names":["result: string | undefined"],"sources":["../../src/plugin-utils/context-helpers.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 { isSetObject } from \"@stryke/type-checks/is-set-object\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport { UnresolvedContext } from \"../types/context\";\n\n/**\n * Get the organization name from the context\n *\n * @param context - The Powerlines plugin context.\n * @returns The organization name or undefined if not found.\n */\nexport function getOrganizationName(\n context: UnresolvedContext\n): string | undefined {\n let result: string | undefined;\n if (isSetObject(context.workspaceConfig.organization)) {\n result = context.workspaceConfig.organization.name;\n }\n\n if (!result && isSetString(context.workspaceConfig.organization)) {\n result = context.workspaceConfig.organization;\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.maintainers) &&\n context.packageJson.maintainers.length > 0\n ) {\n if (isSetObject(context.packageJson.maintainers[0])) {\n result = (context.packageJson.maintainers[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.maintainers[0])) {\n result = context.packageJson.maintainers[0];\n }\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.author) &&\n context.packageJson.author.length > 0\n ) {\n if (isSetObject(context.packageJson.author[0])) {\n result = (context.packageJson.author[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.author[0])) {\n result = context.packageJson.author[0];\n }\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.contributors) &&\n context.packageJson.contributors.length > 0\n ) {\n if (isSetObject(context.packageJson.contributors[0])) {\n result = (context.packageJson.contributors[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.contributors[0])) {\n result = context.packageJson.contributors[0];\n }\n }\n\n if (!result && isSetString(context.packageJson.namespace)) {\n result = context.packageJson.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.name)) {\n result = context.packageJson.name.replace(/^@/, \"\").replace(/\\/.*$/, \"\");\n }\n\n return result;\n}\n\n/**\n * Get the organization name from the context\n *\n * @param context - The Powerlines plugin context.\n * @returns The organization name or undefined if not found.\n */\nexport function getWorkspaceName(\n context: UnresolvedContext\n): string | undefined {\n let result: string | undefined;\n if (isSetString(context.workspaceConfig.name)) {\n result = context.workspaceConfig.name;\n }\n\n if (!result && isSetString(context.workspaceConfig.namespace)) {\n result = context.workspaceConfig.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.namespace)) {\n result = context.packageJson.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.name)) {\n result = context.packageJson.name.replace(/^@/, \"\").replace(/\\/.*$/, \"\");\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;AA4BA,SAAgB,oBACd,SACoB;CACpB,IAAIA;AACJ,KAAI,YAAY,QAAQ,gBAAgB,aAAa,CACnD,UAAS,QAAQ,gBAAgB,aAAa;AAGhD,KAAI,CAAC,UAAU,YAAY,QAAQ,gBAAgB,aAAa,CAC9D,UAAS,QAAQ,gBAAgB;AAGnC,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,YAAY,IAC9C,QAAQ,YAAY,YAAY,SAAS,GACzC;AACA,MAAI,YAAY,QAAQ,YAAY,YAAY,GAAG,CACjD,UAAU,QAAQ,YAAY,YAAY,GAAwB;AAGpE,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,YAAY,GAAG,CAC5D,UAAS,QAAQ,YAAY,YAAY;;AAI7C,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,OAAO,IACzC,QAAQ,YAAY,OAAO,SAAS,GACpC;AACA,MAAI,YAAY,QAAQ,YAAY,OAAO,GAAG,CAC5C,UAAU,QAAQ,YAAY,OAAO,GAAwB;AAG/D,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,OAAO,GAAG,CACvD,UAAS,QAAQ,YAAY,OAAO;;AAIxC,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,aAAa,IAC/C,QAAQ,YAAY,aAAa,SAAS,GAC1C;AACA,MAAI,YAAY,QAAQ,YAAY,aAAa,GAAG,CAClD,UAAU,QAAQ,YAAY,aAAa,GAAwB;AAGrE,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,aAAa,GAAG,CAC7D,UAAS,QAAQ,YAAY,aAAa;;AAI9C,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,UAAU,CACvD,UAAS,QAAQ,YAAY,UAAU,QAAQ,MAAM,GAAG;AAG1D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,KAAK,CAClD,UAAS,QAAQ,YAAY,KAAK,QAAQ,MAAM,GAAG,CAAC,QAAQ,SAAS,GAAG;AAG1E,QAAO;;;;;;;;AAST,SAAgB,iBACd,SACoB;CACpB,IAAIA;AACJ,KAAI,YAAY,QAAQ,gBAAgB,KAAK,CAC3C,UAAS,QAAQ,gBAAgB;AAGnC,KAAI,CAAC,UAAU,YAAY,QAAQ,gBAAgB,UAAU,CAC3D,UAAS,QAAQ,gBAAgB,UAAU,QAAQ,MAAM,GAAG;AAG9D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,UAAU,CACvD,UAAS,QAAQ,YAAY,UAAU,QAAQ,MAAM,GAAG;AAG1D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,KAAK,CAClD,UAAS,QAAQ,YAAY,KAAK,QAAQ,MAAM,GAAG,CAAC,QAAQ,SAAS,GAAG;AAG1E,QAAO"}
1
+ {"version":3,"file":"context-helpers.mjs","names":[],"sources":["../../src/plugin-utils/context-helpers.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 { isSetObject } from \"@stryke/type-checks/is-set-object\";\nimport { isSetString } from \"@stryke/type-checks/is-set-string\";\nimport { UnresolvedContext } from \"../types/context\";\n\n/**\n * Get the organization name from the context\n *\n * @param context - The Powerlines plugin context.\n * @returns The organization name or undefined if not found.\n */\nexport function getOrganizationName(\n context: UnresolvedContext\n): string | undefined {\n let result: string | undefined;\n if (isSetObject(context.workspaceConfig.organization)) {\n result = context.workspaceConfig.organization.name;\n }\n\n if (!result && isSetString(context.workspaceConfig.organization)) {\n result = context.workspaceConfig.organization;\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.maintainers) &&\n context.packageJson.maintainers.length > 0\n ) {\n if (isSetObject(context.packageJson.maintainers[0])) {\n result = (context.packageJson.maintainers[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.maintainers[0])) {\n result = context.packageJson.maintainers[0];\n }\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.author) &&\n context.packageJson.author.length > 0\n ) {\n if (isSetObject(context.packageJson.author[0])) {\n result = (context.packageJson.author[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.author[0])) {\n result = context.packageJson.author[0];\n }\n }\n\n if (\n !result &&\n Array.isArray(context.packageJson.contributors) &&\n context.packageJson.contributors.length > 0\n ) {\n if (isSetObject(context.packageJson.contributors[0])) {\n result = (context.packageJson.contributors[0] as { name: string }).name;\n }\n\n if (!result && isSetString(context.packageJson.contributors[0])) {\n result = context.packageJson.contributors[0];\n }\n }\n\n if (!result && isSetString(context.packageJson.namespace)) {\n result = context.packageJson.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.name)) {\n result = context.packageJson.name.replace(/^@/, \"\").replace(/\\/.*$/, \"\");\n }\n\n return result;\n}\n\n/**\n * Get the organization name from the context\n *\n * @param context - The Powerlines plugin context.\n * @returns The organization name or undefined if not found.\n */\nexport function getWorkspaceName(\n context: UnresolvedContext\n): string | undefined {\n let result: string | undefined;\n if (isSetString(context.workspaceConfig.name)) {\n result = context.workspaceConfig.name;\n }\n\n if (!result && isSetString(context.workspaceConfig.namespace)) {\n result = context.workspaceConfig.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.namespace)) {\n result = context.packageJson.namespace.replace(/^@/, \"\");\n }\n\n if (!result && isSetString(context.packageJson.name)) {\n result = context.packageJson.name.replace(/^@/, \"\").replace(/\\/.*$/, \"\");\n }\n\n return result;\n}\n"],"mappings":";;;;;;;;;;AA4BA,SAAgB,oBACd,SACoB;CACpB,IAAI;AACJ,KAAI,YAAY,QAAQ,gBAAgB,aAAa,CACnD,UAAS,QAAQ,gBAAgB,aAAa;AAGhD,KAAI,CAAC,UAAU,YAAY,QAAQ,gBAAgB,aAAa,CAC9D,UAAS,QAAQ,gBAAgB;AAGnC,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,YAAY,IAC9C,QAAQ,YAAY,YAAY,SAAS,GACzC;AACA,MAAI,YAAY,QAAQ,YAAY,YAAY,GAAG,CACjD,UAAU,QAAQ,YAAY,YAAY,GAAwB;AAGpE,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,YAAY,GAAG,CAC5D,UAAS,QAAQ,YAAY,YAAY;;AAI7C,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,OAAO,IACzC,QAAQ,YAAY,OAAO,SAAS,GACpC;AACA,MAAI,YAAY,QAAQ,YAAY,OAAO,GAAG,CAC5C,UAAU,QAAQ,YAAY,OAAO,GAAwB;AAG/D,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,OAAO,GAAG,CACvD,UAAS,QAAQ,YAAY,OAAO;;AAIxC,KACE,CAAC,UACD,MAAM,QAAQ,QAAQ,YAAY,aAAa,IAC/C,QAAQ,YAAY,aAAa,SAAS,GAC1C;AACA,MAAI,YAAY,QAAQ,YAAY,aAAa,GAAG,CAClD,UAAU,QAAQ,YAAY,aAAa,GAAwB;AAGrE,MAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,aAAa,GAAG,CAC7D,UAAS,QAAQ,YAAY,aAAa;;AAI9C,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,UAAU,CACvD,UAAS,QAAQ,YAAY,UAAU,QAAQ,MAAM,GAAG;AAG1D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,KAAK,CAClD,UAAS,QAAQ,YAAY,KAAK,QAAQ,MAAM,GAAG,CAAC,QAAQ,SAAS,GAAG;AAG1E,QAAO;;;;;;;;AAST,SAAgB,iBACd,SACoB;CACpB,IAAI;AACJ,KAAI,YAAY,QAAQ,gBAAgB,KAAK,CAC3C,UAAS,QAAQ,gBAAgB;AAGnC,KAAI,CAAC,UAAU,YAAY,QAAQ,gBAAgB,UAAU,CAC3D,UAAS,QAAQ,gBAAgB,UAAU,QAAQ,MAAM,GAAG;AAG9D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,UAAU,CACvD,UAAS,QAAQ,YAAY,UAAU,QAAQ,MAAM,GAAG;AAG1D,KAAI,CAAC,UAAU,YAAY,QAAQ,YAAY,KAAK,CAClD,UAAS,QAAQ,YAAY,KAAK,QAAQ,MAAM,GAAG,CAAC,QAAQ,SAAS,GAAG;AAG1E,QAAO"}
@@ -1,23 +1,24 @@
1
- const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
3
  const require_plugin_utils_merge = require('./merge.cjs');
3
- let __stryke_type_checks_is_function = require("@stryke/type-checks/is-function");
4
- let __stryke_convert_to_array = require("@stryke/convert/to-array");
4
+ let _stryke_type_checks_is_function = require("@stryke/type-checks/is-function");
5
+ let _stryke_convert_to_array = require("@stryke/convert/to-array");
5
6
 
6
7
  //#region src/plugin-utils/extend.ts
7
8
  function extend(plugin, extension) {
8
- if ((0, __stryke_type_checks_is_function.isFunction)(plugin)) {
9
- if ((0, __stryke_type_checks_is_function.isFunction)(extension)) return async (options) => {
10
- const pluginResult = (0, __stryke_convert_to_array.toArray)(await Promise.resolve(plugin(options)));
11
- const extensionResult = (0, __stryke_convert_to_array.toArray)(await Promise.resolve(extension(options)));
9
+ if ((0, _stryke_type_checks_is_function.isFunction)(plugin)) {
10
+ if ((0, _stryke_type_checks_is_function.isFunction)(extension)) return async (options) => {
11
+ const pluginResult = (0, _stryke_convert_to_array.toArray)(await Promise.resolve(plugin(options)));
12
+ const extensionResult = (0, _stryke_convert_to_array.toArray)(await Promise.resolve(extension(options)));
12
13
  return pluginResult.map((p) => extensionResult.map((e) => require_plugin_utils_merge.merge(p, e))).flat();
13
14
  };
14
15
  return async (options) => {
15
- return (0, __stryke_convert_to_array.toArray)(await Promise.resolve(plugin(options))).map((p) => require_plugin_utils_merge.merge(p, extension));
16
+ return (0, _stryke_convert_to_array.toArray)(await Promise.resolve(plugin(options))).map((p) => require_plugin_utils_merge.merge(p, extension));
16
17
  };
17
- } else if ((0, __stryke_type_checks_is_function.isFunction)(extension)) return async (options) => {
18
- return (0, __stryke_convert_to_array.toArray)(await Promise.resolve(extension(options))).map((e) => (0, __stryke_convert_to_array.toArray)(plugin).map((p) => require_plugin_utils_merge.merge(p, e))).flat();
18
+ } else if ((0, _stryke_type_checks_is_function.isFunction)(extension)) return async (options) => {
19
+ return (0, _stryke_convert_to_array.toArray)(await Promise.resolve(extension(options))).map((e) => (0, _stryke_convert_to_array.toArray)(plugin).map((p) => require_plugin_utils_merge.merge(p, e))).flat();
19
20
  };
20
- return (0, __stryke_convert_to_array.toArray)(plugin).map((p) => require_plugin_utils_merge.merge(p, extension));
21
+ return (0, _stryke_convert_to_array.toArray)(plugin).map((p) => require_plugin_utils_merge.merge(p, extension));
21
22
  }
22
23
 
23
24
  //#endregion
@@ -3,7 +3,6 @@ import { PluginContext } from "../types/context.cjs";
3
3
  import { PartialPlugin, PartialPluginFactory, PluginFactory } from "../types/config.cjs";
4
4
 
5
5
  //#region src/plugin-utils/extend.d.ts
6
-
7
6
  /**
8
7
  * Adds additional helper functionality to a plugin via a plugin builder function.
9
8
  *
@@ -1 +1 @@
1
- {"version":3,"file":"extend.d.cts","names":[],"sources":["../../src/plugin-utils/extend.ts"],"sourcesContent":[],"mappings":";;;;;;;;AAoCA;;;;;AAKU,iBALM,MAKN,CAAA,iBAJS,aAIT,GAJyB,aAIzB,EAAA,iBAAA,OAAA,EAAA,oBAAA,OAAA,CAAA,CAAA,MAAA,EAAA,aAAA,CAAc,QAAd,EAAwB,cAAxB,CAAA,EAAA,SAAA,EACG,oBADH,CACwB,QADxB,EACkC,iBADlC,CAAA,CAAA,EAEP,aAFO,CAEO,QAFP,EAEiB,cAFjB,GAEkC,iBAFlC,CAAA;AACwB,iBAElB,MAFkB,CAAA,iBAGf,aAHe,GAGC,aAHD,EAAA,iBAAA,OAAA,CAAA,CAAA,MAAA,EAMxB,aANwB,CAMV,QANU,EAMA,cANA,CAAA,EAAA,SAAA,EAOrB,aAPqB,CAOP,QAPO,CAAA,CAAA,EAQ/B,aAR+B,CAQjB,QARiB,EAQP,cARO,CAAA;AAAU,iBAS5B,MAT4B,CAAA,iBAUzB,aAVyB,GAUT,aAVS,EAAA,oBAAA,OAAA,CAAA,CAAA,MAAA,EAalC,MAbkC,CAa3B,QAb2B,CAAA,GAaf,MAbe,CAaR,QAbQ,CAAA,EAAA,EAAA,SAAA,EAc/B,oBAd+B,CAcV,QAdU,EAcA,iBAdA,CAAA,CAAA,EAezC,aAfyC,CAe3B,QAf2B,EAejB,iBAfiB,CAAA;AAA/B,iBAgBG,MAhBH,CAAA,iBAgB2B,aAhB3B,GAgB2C,aAhB3C,CAAA,CAAA,MAAA,EAiBH,MAjBG,CAiBI,QAjBJ,CAAA,GAiBgB,MAjBhB,CAiBuB,QAjBvB,CAAA,EAAA,EAAA,SAAA,EAkBA,aAlBA,CAkBc,QAlBd,CAAA,CAAA,EAmBV,MAnBU,CAmBH,QAnBG,CAAA,EAAA"}
1
+ {"version":3,"file":"extend.d.cts","names":[],"sources":["../../src/plugin-utils/extend.ts"],"mappings":";;;;;;;AAoCA;;;;;iBAAgB,MAAA,kBACG,aAAA,GAAgB,aAAA,wDAAA,CAIjC,MAAA,EAAQ,aAAA,CAAc,QAAA,EAAU,cAAA,GAChC,SAAA,EAAW,oBAAA,CAAqB,QAAA,EAAU,iBAAA,IACzC,aAAA,CAAc,QAAA,EAAU,cAAA,GAAiB,iBAAA;AAAA,iBAC5B,MAAA,kBACG,aAAA,GAAgB,aAAA,2BAAA,CAGjC,MAAA,EAAQ,aAAA,CAAc,QAAA,EAAU,cAAA,GAChC,SAAA,EAAW,aAAA,CAAc,QAAA,IACxB,aAAA,CAAc,QAAA,EAAU,cAAA;AAAA,iBACX,MAAA,kBACG,aAAA,GAAgB,aAAA,8BAAA,CAGjC,MAAA,EAAQ,MAAA,CAAO,QAAA,IAAY,MAAA,CAAO,QAAA,KAClC,SAAA,EAAW,oBAAA,CAAqB,QAAA,EAAU,iBAAA,IACzC,aAAA,CAAc,QAAA,EAAU,iBAAA;AAAA,iBACX,MAAA,kBAAwB,aAAA,GAAgB,aAAA,CAAA,CACtD,MAAA,EAAQ,MAAA,CAAO,QAAA,IAAY,MAAA,CAAO,QAAA,KAClC,SAAA,EAAW,aAAA,CAAc,QAAA,IACxB,MAAA,CAAO,QAAA"}
@@ -3,7 +3,6 @@ import { PluginContext } from "../types/context.mjs";
3
3
  import { PartialPlugin, PartialPluginFactory, PluginFactory } from "../types/config.mjs";
4
4
 
5
5
  //#region src/plugin-utils/extend.d.ts
6
-
7
6
  /**
8
7
  * Adds additional helper functionality to a plugin via a plugin builder function.
9
8
  *
@@ -1 +1 @@
1
- {"version":3,"file":"extend.d.mts","names":[],"sources":["../../src/plugin-utils/extend.ts"],"sourcesContent":[],"mappings":";;;;;;;;AAoCA;;;;;AAKU,iBALM,MAKN,CAAA,iBAJS,aAIT,GAJyB,aAIzB,EAAA,iBAAA,OAAA,EAAA,oBAAA,OAAA,CAAA,CAAA,MAAA,EAAA,aAAA,CAAc,QAAd,EAAwB,cAAxB,CAAA,EAAA,SAAA,EACG,oBADH,CACwB,QADxB,EACkC,iBADlC,CAAA,CAAA,EAEP,aAFO,CAEO,QAFP,EAEiB,cAFjB,GAEkC,iBAFlC,CAAA;AACwB,iBAElB,MAFkB,CAAA,iBAGf,aAHe,GAGC,aAHD,EAAA,iBAAA,OAAA,CAAA,CAAA,MAAA,EAMxB,aANwB,CAMV,QANU,EAMA,cANA,CAAA,EAAA,SAAA,EAOrB,aAPqB,CAOP,QAPO,CAAA,CAAA,EAQ/B,aAR+B,CAQjB,QARiB,EAQP,cARO,CAAA;AAAU,iBAS5B,MAT4B,CAAA,iBAUzB,aAVyB,GAUT,aAVS,EAAA,oBAAA,OAAA,CAAA,CAAA,MAAA,EAalC,MAbkC,CAa3B,QAb2B,CAAA,GAaf,MAbe,CAaR,QAbQ,CAAA,EAAA,EAAA,SAAA,EAc/B,oBAd+B,CAcV,QAdU,EAcA,iBAdA,CAAA,CAAA,EAezC,aAfyC,CAe3B,QAf2B,EAejB,iBAfiB,CAAA;AAA/B,iBAgBG,MAhBH,CAAA,iBAgB2B,aAhB3B,GAgB2C,aAhB3C,CAAA,CAAA,MAAA,EAiBH,MAjBG,CAiBI,QAjBJ,CAAA,GAiBgB,MAjBhB,CAiBuB,QAjBvB,CAAA,EAAA,EAAA,SAAA,EAkBA,aAlBA,CAkBc,QAlBd,CAAA,CAAA,EAmBV,MAnBU,CAmBH,QAnBG,CAAA,EAAA"}
1
+ {"version":3,"file":"extend.d.mts","names":[],"sources":["../../src/plugin-utils/extend.ts"],"mappings":";;;;;;;AAoCA;;;;;iBAAgB,MAAA,kBACG,aAAA,GAAgB,aAAA,wDAAA,CAIjC,MAAA,EAAQ,aAAA,CAAc,QAAA,EAAU,cAAA,GAChC,SAAA,EAAW,oBAAA,CAAqB,QAAA,EAAU,iBAAA,IACzC,aAAA,CAAc,QAAA,EAAU,cAAA,GAAiB,iBAAA;AAAA,iBAC5B,MAAA,kBACG,aAAA,GAAgB,aAAA,2BAAA,CAGjC,MAAA,EAAQ,aAAA,CAAc,QAAA,EAAU,cAAA,GAChC,SAAA,EAAW,aAAA,CAAc,QAAA,IACxB,aAAA,CAAc,QAAA,EAAU,cAAA;AAAA,iBACX,MAAA,kBACG,aAAA,GAAgB,aAAA,8BAAA,CAGjC,MAAA,EAAQ,MAAA,CAAO,QAAA,IAAY,MAAA,CAAO,QAAA,KAClC,SAAA,EAAW,oBAAA,CAAqB,QAAA,EAAU,iBAAA,IACzC,aAAA,CAAc,QAAA,EAAU,iBAAA;AAAA,iBACX,MAAA,kBAAwB,aAAA,GAAgB,aAAA,CAAA,CACtD,MAAA,EAAQ,MAAA,CAAO,QAAA,IAAY,MAAA,CAAO,QAAA,KAClC,SAAA,EAAW,aAAA,CAAc,QAAA,IACxB,MAAA,CAAO,QAAA"}
@@ -1,7 +1,8 @@
1
- const require_rolldown_runtime = require('../_virtual/rolldown_runtime.cjs');
1
+ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
2
+ const require_runtime = require('../_virtual/_rolldown/runtime.cjs');
2
3
  const require_lib_utilities_format = require('../lib/utilities/format.cjs');
3
- let __stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
4
- let __stryke_path_join = require("@stryke/path/join");
4
+ let _stryke_type_checks_is_set_string = require("@stryke/type-checks/is-set-string");
5
+ let _stryke_path_join = require("@stryke/path/join");
5
6
 
6
7
  //#region src/plugin-utils/format-package-json.ts
7
8
  /**
@@ -10,9 +11,9 @@ let __stryke_path_join = require("@stryke/path/join");
10
11
  * @param context - The powerlines context.
11
12
  */
12
13
  async function formatPackageJson(context) {
13
- const packageJsonPath = (0, __stryke_path_join.joinPaths)(context.workspaceConfig.workspaceRoot, context.config.root, "package.json");
14
+ const packageJsonPath = (0, _stryke_path_join.joinPaths)(context.workspaceConfig.workspaceRoot, context.config.root, "package.json");
14
15
  const packageJsonFile = await context.fs.read(packageJsonPath);
15
- if ((0, __stryke_type_checks_is_set_string.isSetString)(packageJsonFile)) await context.fs.write(packageJsonPath, await require_lib_utilities_format.format(context, packageJsonPath, packageJsonFile));
16
+ if ((0, _stryke_type_checks_is_set_string.isSetString)(packageJsonFile)) await context.fs.write(packageJsonPath, await require_lib_utilities_format.format(context, packageJsonPath, packageJsonFile));
16
17
  }
17
18
 
18
19
  //#endregion
@@ -1,7 +1,6 @@
1
1
  import { Context } from "../types/context.cjs";
2
2
 
3
3
  //#region src/plugin-utils/format-package-json.d.ts
4
-
5
4
  /**
6
5
  * Formats the `package.json` file in the project root.
7
6
  *
@@ -1 +1 @@
1
- {"version":3,"file":"format-package-json.d.cts","names":[],"sources":["../../src/plugin-utils/format-package-json.ts"],"sourcesContent":[],"mappings":";;;;;;AA4BA;;;iBAAsB,iBAAA,UAA2B,UAAO"}
1
+ {"version":3,"file":"format-package-json.d.cts","names":[],"sources":["../../src/plugin-utils/format-package-json.ts"],"mappings":";;;;;AA4BA;;;iBAAsB,iBAAA,CAAkB,OAAA,EAAS,OAAA,GAAO,OAAA"}
@@ -1,7 +1,6 @@
1
1
  import { Context } from "../types/context.mjs";
2
2
 
3
3
  //#region src/plugin-utils/format-package-json.d.ts
4
-
5
4
  /**
6
5
  * Formats the `package.json` file in the project root.
7
6
  *
@@ -1 +1 @@
1
- {"version":3,"file":"format-package-json.d.mts","names":[],"sources":["../../src/plugin-utils/format-package-json.ts"],"sourcesContent":[],"mappings":";;;;;;AA4BA;;;iBAAsB,iBAAA,UAA2B,UAAO"}
1
+ {"version":3,"file":"format-package-json.d.mts","names":[],"sources":["../../src/plugin-utils/format-package-json.ts"],"mappings":";;;;;AA4BA;;;iBAAsB,iBAAA,CAAkB,OAAA,EAAS,OAAA,GAAO,OAAA"}