@reliverse/dler 1.7.113 → 1.7.115

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 (154) hide show
  1. package/bin/app/add/add-local/core/templates.d.ts +3 -3
  2. package/bin/app/add/add-local/core/templates.js +8 -8
  3. package/bin/app/add/cmd.js +2 -2
  4. package/bin/app/ai/ai-impl/ai-chat.d.ts +2 -2
  5. package/bin/app/ai/ai-impl/ai-types.d.ts +2 -2
  6. package/bin/app/ai/ai-impl/relinter/relinter.d.ts +2 -2
  7. package/bin/app/ai/ai-menu.d.ts +2 -2
  8. package/bin/app/ai/cmd.js +4 -4
  9. package/bin/app/better/auth/cmd.js +1 -6
  10. package/bin/app/build/build-library.d.ts +5 -4
  11. package/bin/app/build/build-regular.d.ts +4 -3
  12. package/bin/app/build/cmd.d.ts +10 -0
  13. package/bin/app/build/cmd.js +29 -12
  14. package/bin/app/build/impl.d.ts +3 -2
  15. package/bin/app/build/library-flow.d.ts +5 -4
  16. package/bin/app/build/postbuild.d.ts +2 -2
  17. package/bin/app/build/postbuild.js +0 -6
  18. package/bin/app/build/prebuild.d.ts +2 -2
  19. package/bin/app/build/prebuild.js +0 -6
  20. package/bin/app/build/regular-flow.d.ts +4 -3
  21. package/bin/app/check/cmd.js +2 -2
  22. package/bin/app/config/constants.d.ts +1 -1
  23. package/bin/app/config/constants.js +1 -1
  24. package/bin/app/config/content.d.ts +1 -1
  25. package/bin/app/config/content.js +2 -2
  26. package/bin/app/config/core-cfg.d.ts +5 -5
  27. package/bin/app/config/core-cfg.js +27 -16
  28. package/bin/app/config/create.d.ts +6 -5
  29. package/bin/app/config/create.js +13 -22
  30. package/bin/app/config/def-utils.d.ts +3 -3
  31. package/bin/app/config/def-utils.js +10 -8
  32. package/bin/app/config/detect.d.ts +4 -2
  33. package/bin/app/config/detect.js +36 -6
  34. package/bin/app/config/gen-cfg.js +4 -4
  35. package/bin/app/config/load.d.ts +2 -2
  36. package/bin/app/config/load.js +1 -1
  37. package/bin/app/config/migrate.d.ts +1 -1
  38. package/bin/app/config/migrate.js +7 -3
  39. package/bin/app/config/path.d.ts +1 -1
  40. package/bin/app/config/path.js +3 -3
  41. package/bin/app/config/prepare.d.ts +1 -1
  42. package/bin/app/config/prepare.js +83 -81
  43. package/bin/app/config/prompts.d.ts +1 -1
  44. package/bin/app/config/prompts.js +1 -1
  45. package/bin/app/config/read.d.ts +3 -3
  46. package/bin/app/config/read.js +13 -35
  47. package/bin/app/config/repair.d.ts +2 -2
  48. package/bin/app/config/repair.js +12 -12
  49. package/bin/app/config/unstable.d.ts +3 -3
  50. package/bin/app/config/unstable.js +2 -14
  51. package/bin/app/config/update.d.ts +3 -3
  52. package/bin/app/config/update.js +41 -48
  53. package/bin/app/env/env-impl.js +2 -2
  54. package/bin/app/init/cmd-2.js +2 -2
  55. package/bin/app/init/init-utils/init-utils.js +7 -7
  56. package/bin/app/init/init-utils/mm-deprecated/editor-menu.d.ts +3 -2
  57. package/bin/app/init/init-utils/mm-deprecated/editor-menu.js +1 -6
  58. package/bin/app/init/use-template/cp-impl.d.ts +5 -4
  59. package/bin/app/init/use-template/cp-mod.d.ts +3 -3
  60. package/bin/app/init/use-template/cp-mod.js +5 -5
  61. package/bin/app/init/use-template/cp-modules/cli-main-modules/cli-menu-items/showCloneProjectMenu.d.ts +2 -2
  62. package/bin/app/init/use-template/cp-modules/compose-env-file/cef-impl.d.ts +2 -2
  63. package/bin/app/init/use-template/cp-modules/compose-env-file/cef-mod.d.ts +2 -2
  64. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/deploy.d.ts +4 -3
  65. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/gdp-mod.d.ts +5 -4
  66. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/git.d.ts +6 -5
  67. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/github.d.ts +2 -2
  68. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/utils-private-repo.d.ts +2 -2
  69. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/utils-private-repo.js +6 -3
  70. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/utils-repo-exists.d.ts +3 -2
  71. package/bin/app/init/use-template/cp-modules/git-deploy-prompts/utils-repo-exists.js +4 -4
  72. package/bin/app/invoke/cmd.js +2 -2
  73. package/bin/app/mrse/cmd.js +2 -2
  74. package/bin/app/mrse/mrse-impl.js +2 -2
  75. package/bin/app/providers/better-t-stack/types.d.ts +9 -9
  76. package/bin/app/providers/package.json +3 -0
  77. package/bin/app/providers/reliverse-stack/reliverse-stack-mod.js +2 -2
  78. package/bin/app/providers/reliverse-stack/rs-impl.d.ts +4 -4
  79. package/bin/app/pub/cmd.d.ts +10 -0
  80. package/bin/app/pub/cmd.js +27 -12
  81. package/bin/app/pub/impl.d.ts +3 -2
  82. package/bin/app/rempts/cmd.js +2 -2
  83. package/bin/app/rules/reliverse/dler-config-health/dler-config-health.d.ts +1 -1
  84. package/bin/app/rules/reliverse/dler-config-health/dler-config-health.js +1 -1
  85. package/bin/app/schema/cmd.js +3 -3
  86. package/bin/app/{config/reltypes-content.js → schema/gen.js} +474 -228
  87. package/bin/app/schema/mod.d.ts +1224 -0
  88. package/bin/app/schema/mod.js +329 -0
  89. package/bin/app/{config/reltypes-utils.js → schema/utils.js} +6 -3
  90. package/bin/app/toolbox/cmd.js +2 -2
  91. package/bin/app/toolbox/toolbox-impl.d.ts +3 -2
  92. package/bin/app/types/mod.d.ts +10 -1518
  93. package/bin/app/types/mod.js +0 -161
  94. package/bin/app/update/impl.d.ts +1 -0
  95. package/bin/app/update/impl.js +102 -1
  96. package/bin/app/utils/common.d.ts +3 -0
  97. package/bin/app/utils/common.js +28 -0
  98. package/bin/app/utils/decideHelper.d.ts +2 -2
  99. package/bin/app/utils/downloading/downloadRepo.d.ts +2 -2
  100. package/bin/app/utils/downloading/downloadRepo.js +3 -3
  101. package/bin/app/utils/downloading/handleDownload.d.ts +2 -2
  102. package/bin/app/utils/finalize.d.ts +2 -1
  103. package/bin/app/utils/handlers/handleCleanup.js +2 -2
  104. package/bin/app/utils/handlers/handleCodemods.d.ts +2 -2
  105. package/bin/app/utils/projectRepository.d.ts +3 -4
  106. package/bin/app/utils/prompts/askUsernameFrontend.d.ts +2 -2
  107. package/bin/app/utils/prompts/askUsernameFrontend.js +3 -3
  108. package/bin/app/utils/resolve-cross-libs.js +2 -2
  109. package/bin/app/utils/startEndPrompts.d.ts +8 -2
  110. package/bin/app/utils/startEndPrompts.js +43 -12
  111. package/bin/app/utils/utils-build.d.ts +2 -2
  112. package/bin/app/utils/utils-clean.d.ts +1 -1
  113. package/bin/app/utils/utils-deps.d.ts +2 -2
  114. package/bin/app/utils/utils-determine.d.ts +1 -1
  115. package/bin/app/utils/utils-jsr-json.d.ts +2 -2
  116. package/bin/app/utils/utils-package-json-libraries.d.ts +3 -3
  117. package/bin/app/utils/utils-package-json-regular.d.ts +2 -2
  118. package/bin/dler.js +2 -92
  119. package/bin/mod.d.ts +431 -438
  120. package/bin/mod.js +36 -27
  121. package/package.json +12 -10
  122. package/bin/app/agg/cmd.d.ts +0 -72
  123. package/bin/app/agg/cmd.js +0 -128
  124. package/bin/app/cli/cmd.d.ts +0 -12
  125. package/bin/app/cli/cmd.js +0 -56
  126. package/bin/app/cli/impl.d.ts +0 -3
  127. package/bin/app/cli/impl.js +0 -88
  128. package/bin/app/config/default-cfg.d.ts +0 -3
  129. package/bin/app/config/default-cfg.js +0 -155
  130. package/bin/app/config/default.d.ts +0 -6
  131. package/bin/app/config/default.js +0 -159
  132. package/bin/app/config/schema.d.ts +0 -130
  133. package/bin/app/config/schema.js +0 -443
  134. package/bin/app/init/use-template/cp-modules/cli-main-modules/cli-menu-items/getMainMenuOptions.d.ts +0 -12
  135. package/bin/app/init/use-template/cp-modules/cli-main-modules/cli-menu-items/getMainMenuOptions.js +0 -69
  136. package/bin/app/init/use-template/cp-modules/cli-main-modules/modules/showStartEndPrompt.d.ts +0 -2
  137. package/bin/app/init/use-template/cp-modules/cli-main-modules/modules/showStartEndPrompt.js +0 -26
  138. package/bin/app/schema/schema-impl.d.ts +0 -2
  139. package/bin/app/schema/schema-impl.js +0 -24
  140. package/bin/app/update/cmd.d.ts +0 -103
  141. package/bin/app/update/cmd.js +0 -299
  142. package/bin/app/utils/native-cli/nc-impl.d.ts +0 -15
  143. package/bin/app/utils/native-cli/nc-impl.js +0 -154
  144. package/bin/app/utils/native-cli/nc-mod.d.ts +0 -3
  145. package/bin/app/utils/native-cli/nc-mod.js +0 -44
  146. package/bin/app/web/README.md +0 -149
  147. package/bin/app/web/cmd.d.ts +0 -2
  148. package/bin/app/web/cmd.js +0 -11
  149. package/bin/dler-go +0 -4
  150. package/bin/dler-rust +0 -4
  151. /package/bin/app/{config/reltypes-content.d.ts → schema/gen.d.ts} +0 -0
  152. /package/bin/app/{config/reltypes-utils.d.ts → schema/utils.d.ts} +0 -0
  153. /package/bin/app/utils/{hasOnlyRseConfig.d.ts → hasOnlyReliverseConfig.d.ts} +0 -0
  154. /package/bin/app/utils/{hasOnlyRseConfig.js → hasOnlyReliverseConfig.js} +0 -0
@@ -1,4 +1,4 @@
1
- import type { RseConfig } from "../../../types/mod.js";
1
+ import type { ReliverseConfig } from "../../../schema/mod.js";
2
2
  /**
3
3
  * Type for template update check results
4
4
  */
@@ -12,7 +12,7 @@ export interface TemplateUpdateInfo {
12
12
  * @param projectConfig The project's rseg
13
13
  * @returns Object containing update info
14
14
  */
15
- export declare function checkForTemplateUpdate(projectConfig: RseConfig): Promise<TemplateUpdateInfo>;
15
+ export declare function checkForTemplateUpdate(projectConfig: ReliverseConfig): Promise<TemplateUpdateInfo>;
16
16
  /**
17
17
  * Updates the project template date in the config to the latest date
18
18
  * @param projectPath The path to the project directory
@@ -23,7 +23,7 @@ export declare function updateProjectTemplateDate(projectPath: string, latestDat
23
23
  /**
24
24
  * Retrieves template update info (if any) based on rseg presence.
25
25
  */
26
- export declare function getTemplateUpdateInfo(cwd: string, isDev: boolean, hasRseConfig: boolean): Promise<{
26
+ export declare function getTemplateUpdateInfo(cwd: string, isDev: boolean, hasReliverseConfig: boolean): Promise<{
27
27
  updateAvailable: boolean;
28
28
  updateInfo: TemplateUpdateInfo | null;
29
29
  }>;
@@ -1,9 +1,9 @@
1
1
  import { relinka } from "@reliverse/relinka";
2
2
  import { ofetch } from "ofetch";
3
3
  import { UNKNOWN_VALUE } from "../../../config/constants.js";
4
- import { getRseConfigPath } from "../../../config/path.js";
5
- import { readRseConfig } from "../../../config/read.js";
6
- import { updateRseConfig } from "../../../config/update.js";
4
+ import { getReliverseConfigPath } from "../../../config/path.js";
5
+ import { readReliverseConfig } from "../../../config/read.js";
6
+ import { updateReliverseConfig } from "../../../config/update.js";
7
7
  import { REPO_TEMPLATES } from "../../../utils/projectRepository.js";
8
8
  export async function checkForTemplateUpdate(projectConfig) {
9
9
  if (!projectConfig.projectTemplate || projectConfig.projectTemplate === UNKNOWN_VALUE) {
@@ -61,7 +61,7 @@ export async function checkForTemplateUpdate(projectConfig) {
61
61
  }
62
62
  export async function updateProjectTemplateDate(projectPath, latestDate, isDev) {
63
63
  try {
64
- await updateRseConfig(projectPath, { projectTemplateDate: latestDate }, isDev);
64
+ await updateReliverseConfig(projectPath, { projectTemplateDate: latestDate }, isDev);
65
65
  relinka("success", `Updated project template date to ${latestDate}`);
66
66
  } catch (error) {
67
67
  relinka(
@@ -70,12 +70,12 @@ export async function updateProjectTemplateDate(projectPath, latestDate, isDev)
70
70
  );
71
71
  }
72
72
  }
73
- export async function getTemplateUpdateInfo(cwd, isDev, hasRseConfig) {
73
+ export async function getTemplateUpdateInfo(cwd, isDev, hasReliverseConfig) {
74
74
  let updateInfo = null;
75
75
  let updateAvailable = false;
76
- if (hasRseConfig) {
77
- const { configPath } = await getRseConfigPath(cwd, isDev, false);
78
- const projectConfig = await readRseConfig(configPath, isDev);
76
+ if (hasReliverseConfig) {
77
+ const { configPath } = await getReliverseConfigPath(cwd, isDev, false);
78
+ const projectConfig = await readReliverseConfig(configPath, isDev);
79
79
  if (projectConfig) {
80
80
  updateInfo = await checkForTemplateUpdate(projectConfig);
81
81
  updateAvailable = updateInfo.hasUpdate;
@@ -1,6 +1,6 @@
1
1
  import { relinka } from "@reliverse/relinka";
2
2
  import { defineCommand } from "@reliverse/rempts";
3
- import { getOrCreateRseConfig } from "../config/core-cfg.js";
3
+ import { getOrCreateReliverseConfig } from "../config/core-cfg.js";
4
4
  import { showManualBuilderMenu } from "../init/init-utils/init-impl.js";
5
5
  import { getOrCreateReliverseMemory } from "../utils/reliverseMemory.js";
6
6
  import { getCurrentWorkingDirectory } from "../utils/terminalHelpers.js";
@@ -36,7 +36,7 @@ export default defineCommand({
36
36
  relinka("verbose", "Using dev mode");
37
37
  }
38
38
  const cwd = getCurrentWorkingDirectory();
39
- const { config } = await getOrCreateRseConfig({
39
+ const { config } = await getOrCreateReliverseConfig({
40
40
  projectPath: cwd,
41
41
  isDev,
42
42
  overrides: {}
@@ -1,5 +1,5 @@
1
- import type { RseConfig } from "../../types/mod.js";
1
+ import type { ReliverseConfig } from "../../schema/mod.js";
2
2
  /**
3
3
  * Initiates a loop to capture user input and provide AI responses.
4
4
  */
5
- export declare function aiChat(config: RseConfig): Promise<void>;
5
+ export declare function aiChat(config: ReliverseConfig): Promise<void>;
@@ -1,10 +1,10 @@
1
- import type { RseConfig } from "../../types/mod.js";
1
+ import type { ReliverseConfig } from "../../schema/mod.js";
2
2
  import type { ReliverseMemory } from "../../utils/schemaMemory.js";
3
3
  import type { AGENT_NAMES, CIRCULAR_TRIGGERS } from "./ai-const";
4
4
  export type CircularTrigger = (typeof CIRCULAR_TRIGGERS)[number];
5
5
  export type AiSdkAgent = (typeof AGENT_NAMES)[number];
6
6
  export interface AIAgentOptions {
7
- config: RseConfig;
7
+ config: ReliverseConfig;
8
8
  agent: AiSdkAgent;
9
9
  isKeyEnsured: boolean;
10
10
  memory?: ReliverseMemory;
@@ -1,4 +1,4 @@
1
- import type { RseConfig } from "../../../types/mod.js";
1
+ import type { ReliverseConfig } from "../../../schema/mod.js";
2
2
  /**
3
3
  * Describes a lint suggestion with file details and a recommended fix or note.
4
4
  */
@@ -12,7 +12,7 @@ export interface LintSuggestion {
12
12
  /**
13
13
  * Coordinates the relinter process. Accepts multiple target paths.
14
14
  */
15
- export declare function agentRelinter(config: RseConfig, targetPaths: string[], task?: string): Promise<void>;
15
+ export declare function agentRelinter(config: ReliverseConfig, targetPaths: string[], task?: string): Promise<void>;
16
16
  /**
17
17
  * Collects a list of recognized code files from a path.
18
18
  */
@@ -1,3 +1,3 @@
1
- import type { RseConfig } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
2
  import type { ReliverseMemory } from "../utils/schemaMemory.js";
3
- export declare function aiMenu(config: RseConfig, isKeyEnsured: boolean, memory?: ReliverseMemory): Promise<void>;
3
+ export declare function aiMenu(config: ReliverseConfig, isKeyEnsured: boolean, memory?: ReliverseMemory): Promise<void>;
package/bin/app/ai/cmd.js CHANGED
@@ -4,8 +4,8 @@ import { ensureOpenAIKey } from "./ai-impl/ai-auth.js";
4
4
  import { AGENT_NAMES } from "./ai-impl/ai-const.js";
5
5
  import { aiAgenticTool } from "./ai-impl/ai-tools.js";
6
6
  import { aiMenu } from "./ai-menu.js";
7
- import { getRseConfigPath } from "../config/path.js";
8
- import { readRseConfig } from "../config/read.js";
7
+ import { getReliverseConfigPath } from "../config/path.js";
8
+ import { readReliverseConfig } from "../config/read.js";
9
9
  import { getOrCreateReliverseMemory } from "../utils/reliverseMemory.js";
10
10
  import { getCurrentWorkingDirectory } from "../utils/terminalHelpers.js";
11
11
  export default defineCommand({
@@ -37,8 +37,8 @@ export default defineCommand({
37
37
  relinka("verbose", "Using dev mode");
38
38
  }
39
39
  const cwd = getCurrentWorkingDirectory();
40
- const { configPath } = await getRseConfigPath(cwd, isDev, false);
41
- const config = await readRseConfig(configPath, isDev);
40
+ const { configPath } = await getReliverseConfigPath(cwd, isDev, false);
41
+ const config = await readReliverseConfig(configPath, isDev);
42
42
  if (!config) {
43
43
  throw new Error("Failed to read rse config");
44
44
  }
@@ -1,10 +1,9 @@
1
1
  import path from "@reliverse/pathkit";
2
2
  import fs from "@reliverse/relifso";
3
3
  import { relinka } from "@reliverse/relinka";
4
- import { callCmd, defineArgs, defineCommand } from "@reliverse/rempts";
4
+ import { defineArgs, defineCommand } from "@reliverse/rempts";
5
5
  import { execaCommand } from "execa";
6
6
  import MagicString from "magic-string";
7
- import { default as betterAuthGenerateCmd } from "./generate/cmd.js";
8
7
  import { configPath, schemaPath } from "./consts.js";
9
8
  const notice = `/**
10
9
  * THIS FILE IS AUTO-GENERATED - DO NOT EDIT DIRECTLY
@@ -43,10 +42,6 @@ export default defineCommand({
43
42
  relinka("error", "Schema file does not exist; tried:", args.schema);
44
43
  process.exit(1);
45
44
  }
46
- await callCmd(betterAuthGenerateCmd, {
47
- config: configPath,
48
- output: schemaPath
49
- });
50
45
  const filePath = path.resolve(schemaPath);
51
46
  const originalContent = await fs.readFile(filePath, "utf8");
52
47
  const s = new MagicString(originalContent);
@@ -1,4 +1,5 @@
1
- import type { BundlerName, DlerConfig, Esbuild, LibConfig, NpmOutExt, PerfTimer, Sourcemap, transpileFormat, transpileTarget } from "../types/mod.js";
1
+ import type { BundlerName, Esbuild, LibConfig, NpmOutExt, ReliverseConfig, Sourcemap, TranspileFormat, TranspileTarget } from "../schema/mod.js";
2
+ import type { PerfTimer } from "../types/mod.js";
2
3
  /** Options specific to the NPM build target */
3
4
  interface NpmBuildOptions {
4
5
  npmOutDir: string;
@@ -12,7 +13,7 @@ interface JsrBuildOptions {
12
13
  distJsrOutFilesExt: NpmOutExt;
13
14
  }
14
15
  /** Consolidated options for the main library build function */
15
- export type LibraryBuildOptions = DlerConfig & {
16
+ export type LibraryBuildOptions = ReliverseConfig & {
16
17
  effectivePubRegistry: "npm" | "jsr" | "npm-jsr" | undefined;
17
18
  npm?: NpmBuildOptions;
18
19
  jsr?: JsrBuildOptions;
@@ -23,8 +24,8 @@ export type LibraryBuildOptions = DlerConfig & {
23
24
  libsList: Record<string, LibConfig>;
24
25
  timer: PerfTimer;
25
26
  libTranspileMinify: boolean;
26
- transpileTarget: transpileTarget;
27
- transpileFormat: transpileFormat;
27
+ transpileTarget: TranspileTarget;
28
+ transpileFormat: TranspileFormat;
28
29
  transpileSplitting: boolean;
29
30
  transpileSourcemap: Sourcemap;
30
31
  transpilePublicPath: string;
@@ -1,4 +1,5 @@
1
- import type { BundlerName, DlerConfig, NpmOutExt, PerfTimer, Sourcemap, transpileFormat, transpileTarget } from "../types/mod.js";
1
+ import type { BundlerName, NpmOutExt, ReliverseConfig, Sourcemap, TranspileFormat, TranspileTarget } from "../schema/mod.js";
2
+ import type { PerfTimer } from "../types/mod.js";
2
3
  /**
3
4
  * Builds a regular JSR distribution.
4
5
  * - Copies the entire source directory if `distJsrBuilder` = "jsr"
@@ -7,7 +8,7 @@ import type { BundlerName, DlerConfig, NpmOutExt, PerfTimer, Sourcemap, transpil
7
8
  export declare function regular_buildJsrDist(isDev: boolean, isJsr: boolean, coreIsCLI: {
8
9
  enabled: boolean;
9
10
  scripts: Record<string, string>;
10
- }, coreEntrySrcDir: string, distJsrDirName: string, distJsrBuilder: BundlerName, coreEntryFile: string, transpileTarget: transpileTarget, transpileFormat: transpileFormat, transpileSplitting: boolean, transpileMinify: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, unifiedBundlerOutExt: NpmOutExt, config: DlerConfig, timer: PerfTimer, transpileStub: boolean, transpileWatch: boolean, distJsrGenTsconfig: boolean, coreDeclarations: boolean): Promise<void>;
11
+ }, coreEntrySrcDir: string, distJsrDirName: string, distJsrBuilder: BundlerName, coreEntryFile: string, transpileTarget: TranspileTarget, transpileFormat: TranspileFormat, transpileSplitting: boolean, transpileMinify: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, unifiedBundlerOutExt: NpmOutExt, config: ReliverseConfig, timer: PerfTimer, transpileStub: boolean, transpileWatch: boolean, distJsrGenTsconfig: boolean, coreDeclarations: boolean): Promise<void>;
11
12
  /**
12
13
  * Builds a regular NPM distribution.
13
14
  * - Copies entire src dir if "jsr"
@@ -16,4 +17,4 @@ export declare function regular_buildJsrDist(isDev: boolean, isJsr: boolean, cor
16
17
  export declare function regular_buildNpmDist(isDev: boolean, coreIsCLI: {
17
18
  enabled: boolean;
18
19
  scripts: Record<string, string>;
19
- }, coreEntrySrcDir: string, distNpmDirName: string, distNpmBuilder: BundlerName, coreEntryFile: string, unifiedBundlerOutExt: NpmOutExt, config: DlerConfig, transpileTarget: transpileTarget, transpileFormat: transpileFormat, transpileSplitting: boolean, transpileMinify: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, transpileStub: boolean, transpileWatch: boolean, timer: PerfTimer, coreDeclarations: boolean): Promise<void>;
20
+ }, coreEntrySrcDir: string, distNpmDirName: string, distNpmBuilder: BundlerName, coreEntryFile: string, unifiedBundlerOutExt: NpmOutExt, config: ReliverseConfig, transpileTarget: TranspileTarget, transpileFormat: TranspileFormat, transpileSplitting: boolean, transpileMinify: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, transpileStub: boolean, transpileWatch: boolean, timer: PerfTimer, coreDeclarations: boolean): Promise<void>;
@@ -1,8 +1,18 @@
1
1
  declare const _default: import("@reliverse/rempts").Command<{
2
+ ci: {
3
+ type: "boolean";
4
+ description: string;
5
+ default: boolean;
6
+ };
2
7
  dev: {
3
8
  type: "boolean";
4
9
  description: string;
5
10
  };
11
+ cwd: {
12
+ type: "string";
13
+ description: string;
14
+ default: string;
15
+ };
6
16
  debugOnlyCopyNonBuildFiles: {
7
17
  type: "boolean";
8
18
  description: string;
@@ -1,20 +1,32 @@
1
- import { relinka } from "@reliverse/relinka";
2
1
  import { defineArgs, defineCommand } from "@reliverse/rempts";
3
- import { dlerBuild } from "./impl.js";
4
2
  import { getConfigDler } from "../config/load.js";
3
+ import { commonEndActions, commonStartActions } from "../utils/common.js";
5
4
  import { finalizeBuild } from "../utils/finalize.js";
6
- import { prepareReliverseEnvironment } from "../config/prepare.js";
5
+ import { getCurrentWorkingDirectory } from "../utils/terminalHelpers.js";
7
6
  import { createPerfTimer } from "../utils/utils-perf.js";
7
+ import { dlerBuild } from "./impl.js";
8
8
  export default defineCommand({
9
9
  meta: {
10
10
  name: "build",
11
- description: "Build the project (without publishing)"
11
+ description: ""
12
12
  },
13
13
  args: defineArgs({
14
+ // Common args
15
+ ci: {
16
+ type: "boolean",
17
+ description: "ci",
18
+ default: !process.stdout.isTTY || !!process.env["CI"]
19
+ },
14
20
  dev: {
15
21
  type: "boolean",
16
- description: "Runs the CLI in dev mode"
22
+ description: "dev"
17
23
  },
24
+ cwd: {
25
+ type: "string",
26
+ description: "cwd",
27
+ default: getCurrentWorkingDirectory()
28
+ },
29
+ // Command specific args
18
30
  debugOnlyCopyNonBuildFiles: {
19
31
  type: "boolean",
20
32
  description: "Only copy non-build files to dist directories"
@@ -24,19 +36,24 @@ export default defineCommand({
24
36
  description: "Don't copy non-build files to dist directories, only build buildPreExtensions files"
25
37
  }
26
38
  }),
27
- async run({ args }) {
28
- const isDev = args.dev;
29
- await prepareReliverseEnvironment(isDev, "ts");
30
- relinka("verbose", `Running in ${isDev ? "dev" : "prod"} mode`);
31
- const config = await getConfigDler();
39
+ run: async ({ args }) => {
40
+ const { ci, cwd, dev, debugOnlyCopyNonBuildFiles, debugDontCopyNonBuildFiles } = args;
41
+ const isCI = Boolean(ci);
42
+ const isDev = Boolean(dev);
43
+ const strCwd = String(cwd);
44
+ const isDebugOnlyCopyNonBuildFiles = Boolean(debugOnlyCopyNonBuildFiles);
45
+ const isDebugDontCopyNonBuildFiles = Boolean(debugDontCopyNonBuildFiles);
46
+ await commonStartActions({ isCI, isDev, strCwd });
32
47
  const timer = createPerfTimer();
48
+ const config = await getConfigDler();
33
49
  await dlerBuild(
34
50
  timer,
35
51
  isDev,
36
52
  config,
37
- args.debugOnlyCopyNonBuildFiles,
38
- args.debugDontCopyNonBuildFiles
53
+ isDebugOnlyCopyNonBuildFiles,
54
+ isDebugDontCopyNonBuildFiles
39
55
  );
40
56
  await finalizeBuild(timer, false, "build");
57
+ await commonEndActions();
41
58
  }
42
59
  });
@@ -1,10 +1,11 @@
1
- import type { DlerConfig, PerfTimer } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
+ import type { PerfTimer } from "../types/mod.js";
2
3
  /**
3
4
  * Main entry point for the dler build process.
4
5
  * Handles building for both main project and libraries.
5
6
  * @see `src-ts/app/pub/impl.ts` for pub main function implementation.
6
7
  */
7
- export declare function dlerBuild(timer: PerfTimer, isDev: boolean, config?: DlerConfig, debugOnlyCopyNonBuildFiles?: boolean, debugDontCopyNonBuildFiles?: boolean, disableOwnSpinner?: boolean): Promise<{
8
+ export declare function dlerBuild(timer: PerfTimer, isDev: boolean, config?: ReliverseConfig, debugOnlyCopyNonBuildFiles?: boolean, debugDontCopyNonBuildFiles?: boolean, disableOwnSpinner?: boolean): Promise<{
8
9
  timer: PerfTimer;
9
10
  effectiveConfig: any;
10
11
  } | undefined>;
@@ -1,12 +1,13 @@
1
- import type { BundlerName, DlerConfig, Esbuild, LibConfig, NpmOutExt, PerfTimer, Sourcemap, transpileFormat, transpileTarget } from "../types/mod.js";
1
+ import type { BundlerName, Esbuild, LibConfig, NpmOutExt, ReliverseConfig, Sourcemap, TranspileFormat, TranspileTarget } from "../schema/mod.js";
2
+ import type { PerfTimer } from "../types/mod.js";
2
3
  /**
3
4
  * Builds libraries based on build mode.
4
5
  */
5
- export declare function library_buildFlow(timer: PerfTimer, isDev: boolean, config: DlerConfig): Promise<void>;
6
+ export declare function library_buildFlow(timer: PerfTimer, isDev: boolean, config: ReliverseConfig): Promise<void>;
6
7
  /**
7
8
  * Publishes libraries based on build mode.
8
9
  */
9
- export declare function library_pubFlow(timer: PerfTimer, isDev: boolean, config: DlerConfig): Promise<void>;
10
+ export declare function library_pubFlow(timer: PerfTimer, isDev: boolean, config: ReliverseConfig): Promise<void>;
10
11
  /**
11
12
  * Builds all libs defined in config.libsList.
12
13
  */
@@ -18,7 +19,7 @@ export declare function libraries_build(isDev: boolean, timer: PerfTimer, libsLi
18
19
  npm: string[];
19
20
  jsr: string[];
20
21
  }>;
21
- }, transpileEsbuild: Esbuild, transpileTarget: transpileTarget, transpileFormat: transpileFormat, transpileSplitting: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, distJsrBuilder: BundlerName, transpileStub: boolean, transpileWatch: boolean, distJsrOutFilesExt: NpmOutExt, config: DlerConfig): Promise<void>;
22
+ }, transpileEsbuild: Esbuild, transpileTarget: TranspileTarget, transpileFormat: TranspileFormat, transpileSplitting: boolean, transpileSourcemap: Sourcemap, transpilePublicPath: string, distJsrBuilder: BundlerName, transpileStub: boolean, transpileWatch: boolean, distJsrOutFilesExt: NpmOutExt, config: ReliverseConfig): Promise<void>;
22
23
  /**
23
24
  * Publishes all libs defined in config.libsList.
24
25
  */
@@ -1,3 +1,3 @@
1
- import type { DlerConfig } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
2
  export declare function dlerPostBuild(isDev: boolean, debugDontCopyNonBuildFiles?: boolean): Promise<void>;
3
- export declare function wrapper_CopyNonBuildFiles(config: DlerConfig): Promise<void>;
3
+ export declare function wrapper_CopyNonBuildFiles(config: ReliverseConfig): Promise<void>;
@@ -1,9 +1,7 @@
1
1
  import path from "@reliverse/pathkit";
2
2
  import fs from "@reliverse/relifso";
3
3
  import { relinka } from "@reliverse/relinka";
4
- import { callCmd } from "@reliverse/rempts";
5
4
  import { glob } from "tinyglobby";
6
- import { default as checkCmd } from "../check/cmd.js";
7
5
  import { PROJECT_ROOT } from "../config/constants.js";
8
6
  import { getConfigDler } from "../config/load.js";
9
7
  import { applyMagicSpells } from "../magic/magic-apply.js";
@@ -170,10 +168,6 @@ const createPostBuildToolRunner = () => ({
170
168
  "dler-check": {
171
169
  name: "Dler Check",
172
170
  async run() {
173
- await callCmd(checkCmd, {
174
- "no-exit": true,
175
- "no-progress": true
176
- });
177
171
  }
178
172
  }
179
173
  });
@@ -1,2 +1,2 @@
1
- import type { DlerConfig } from "../types/mod.js";
2
- export declare function dlerPreBuild(config: DlerConfig): Promise<void>;
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
+ export declare function dlerPreBuild(config: ReliverseConfig): Promise<void>;
@@ -1,9 +1,7 @@
1
1
  import path from "@reliverse/pathkit";
2
2
  import fs from "@reliverse/relifso";
3
3
  import { relinka } from "@reliverse/relinka";
4
- import { callCmd } from "@reliverse/rempts";
5
4
  import { glob } from "tinyglobby";
6
- import { default as checkCmd } from "../check/cmd.js";
7
5
  import { PROJECT_ROOT } from "../config/constants.js";
8
6
  import { executeCommand, executeDlerHooks, isCommandAvailable } from "./ppb-utils.js";
9
7
  const createToolRunner = () => ({
@@ -26,10 +24,6 @@ const createToolRunner = () => ({
26
24
  "dler-check": {
27
25
  name: "Dler Check",
28
26
  async run() {
29
- await callCmd(checkCmd, {
30
- "no-exit": true,
31
- "no-progress": true
32
- });
33
27
  }
34
28
  }
35
29
  });
@@ -1,9 +1,10 @@
1
- import type { DlerConfig, PerfTimer } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
+ import type { PerfTimer } from "../types/mod.js";
2
3
  /**
3
4
  * Builds the main project based on build mode and commonPubRegistry.
4
5
  */
5
- export declare function regular_buildFlow(timer: PerfTimer, isDev: boolean, config: DlerConfig): Promise<void>;
6
+ export declare function regular_buildFlow(timer: PerfTimer, isDev: boolean, config: ReliverseConfig): Promise<void>;
6
7
  /**
7
8
  * Publishes the main project based on commonPubRegistry.
8
9
  */
9
- export declare function regular_pubFlow(timer: PerfTimer, isDev: boolean, config: DlerConfig): Promise<void>;
10
+ export declare function regular_pubFlow(timer: PerfTimer, isDev: boolean, config: ReliverseConfig): Promise<void>;
@@ -3,7 +3,7 @@ import { re } from "@reliverse/relico";
3
3
  import { relinka } from "@reliverse/relinka";
4
4
  import { defineArgs, defineCommand, multiselectPrompt, selectPrompt } from "@reliverse/rempts";
5
5
  import { ensureReliverseConfig } from "../config/prepare.js";
6
- import { checkDlerConfigHealth } from "../rules/reliverse/dler-config-health/dler-config-health.js";
6
+ import { checkReliverseConfigHealth } from "../rules/reliverse/dler-config-health/dler-config-health.js";
7
7
  import { checkFileExtensions } from "../rules/reliverse/file-extensions/file-extensions.js";
8
8
  import { analyzeDependencies } from "../rules/reliverse/missing-deps/analyzer.js";
9
9
  import { checkMissingDependencies } from "../rules/reliverse/missing-deps/deps-mod.js";
@@ -223,7 +223,7 @@ checking directory: ${directory}`);
223
223
  }
224
224
  }
225
225
  if (checks.includes("dler-config-health")) {
226
- const result = await checkDlerConfigHealth();
226
+ const result = await checkReliverseConfigHealth();
227
227
  displayCheckResults("dler configuration health", directory, result);
228
228
  if (!result.success && !args["no-exit"]) {
229
229
  process.exit(1);
@@ -1,5 +1,5 @@
1
1
  export declare const PROJECT_ROOT: string;
2
- export declare const cliVersion = "1.7.113";
2
+ export declare const cliVersion = "1.7.115";
3
3
  export declare const cliName = "@reliverse/rse";
4
4
  export declare const rseName = "@reliverse/rse";
5
5
  export declare const dlerName = "@reliverse/dler";
@@ -1,7 +1,7 @@
1
1
  import os from "node:os";
2
2
  import path from "@reliverse/pathkit";
3
3
  export const PROJECT_ROOT = path.resolve(process.cwd());
4
- const version = "1.7.113";
4
+ const version = "1.7.115";
5
5
  export const cliVersion = version;
6
6
  export const cliName = "@reliverse/rse";
7
7
  export const rseName = "@reliverse/rse";
@@ -1,5 +1,5 @@
1
1
  export interface RequiredProjectContent {
2
- fileRseConfig: boolean;
2
+ fileReliverseConfig: boolean;
3
3
  filePackageJson: boolean;
4
4
  }
5
5
  /**
@@ -4,12 +4,12 @@ import { cliConfigJsonc, cliConfigTs } from "./constants.js";
4
4
  export async function getProjectContent(projectPath) {
5
5
  const configJSONC = path.join(projectPath, cliConfigJsonc);
6
6
  const configTS = path.join(projectPath, cliConfigTs);
7
- const fileRseConfig = await fs.pathExists(configJSONC) || await fs.pathExists(configTS);
7
+ const fileReliverseConfig = await fs.pathExists(configJSONC) || await fs.pathExists(configTS);
8
8
  const filePackageJson = await fs.pathExists(path.join(projectPath, "package.json"));
9
9
  const dirNodeModules = await fs.pathExists(path.join(projectPath, "node_modules"));
10
10
  const dirGit = await fs.pathExists(path.join(projectPath, ".git"));
11
11
  return {
12
- requiredContent: { fileRseConfig, filePackageJson },
12
+ requiredContent: { fileReliverseConfig, filePackageJson },
13
13
  optionalContent: { dirNodeModules, dirGit }
14
14
  };
15
15
  }
@@ -1,14 +1,14 @@
1
- import type { RseConfig } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
2
  /**
3
3
  * Retrieves or creates the main rseg (and any 'mrse' configs).
4
4
  * Allows an optional custom path to the TS config file.
5
5
  */
6
- export declare function getOrCreateRseConfig({ projectPath, isDev, overrides, customTsconfigPath, }: {
6
+ export declare function getOrCreateReliverseConfig({ projectPath, isDev, overrides, customTsconfigPath, }: {
7
7
  projectPath: string;
8
8
  isDev: boolean;
9
- overrides: Partial<RseConfig>;
9
+ overrides: Partial<ReliverseConfig>;
10
10
  customTsconfigPath?: string;
11
11
  }): Promise<{
12
- config: RseConfig;
13
- mrse: RseConfig[];
12
+ config: ReliverseConfig;
13
+ mrse: ReliverseConfig[];
14
14
  }>;
@@ -2,12 +2,12 @@ import path from "@reliverse/pathkit";
2
2
  import fs from "@reliverse/relifso";
3
3
  import { relinka } from "@reliverse/relinka";
4
4
  import { cliConfigJsonc, cliConfigTs, RSE_SCHEMA_DEV, UNKNOWN_VALUE } from "./constants.js";
5
- import { createRseConfig } from "./create.js";
6
- import { DEFAULT_CONFIG_RSE } from "./default-cfg.js";
7
- import { getRseConfigPath } from "./path.js";
8
- import { readRseConfig } from "./read.js";
9
- import { parseAndFixRseConfig } from "./repair.js";
10
- export async function getOrCreateRseConfig({
5
+ import { createReliverseConfig } from "./create.js";
6
+ import { getReliverseConfigPath } from "./path.js";
7
+ import { readReliverseConfig } from "./read.js";
8
+ import { parseAndFixReliverseConfig } from "./repair.js";
9
+ import { DEFAULT_CONFIG_RELIVERSE } from "../schema/mod.js";
10
+ export async function getOrCreateReliverseConfig({
11
11
  projectPath,
12
12
  isDev,
13
13
  overrides,
@@ -22,9 +22,9 @@ export async function getOrCreateRseConfig({
22
22
  const configs = await Promise.all(
23
23
  rseFiles.map(async (file) => {
24
24
  const filePath = path.join(mrseFolderPath, file);
25
- let foundConfig = await readRseConfig(filePath, isDev);
25
+ let foundConfig = await readReliverseConfig(filePath, isDev);
26
26
  if (!foundConfig) {
27
- foundConfig = await parseAndFixRseConfig(filePath, isDev);
27
+ foundConfig = await parseAndFixReliverseConfig(filePath, isDev);
28
28
  }
29
29
  if (!foundConfig) {
30
30
  relinka("warn", `Skipping invalid config file: ${filePath}`);
@@ -32,29 +32,40 @@ export async function getOrCreateRseConfig({
32
32
  return foundConfig;
33
33
  })
34
34
  );
35
- results.push(...configs.filter((cfg) => cfg !== null));
35
+ results.push(
36
+ ...configs.filter((cfg) => cfg !== null)
37
+ );
36
38
  }
37
- const { configPath } = await getRseConfigPath(projectPath, isDev, false, customTsconfigPath);
39
+ const { configPath } = await getReliverseConfigPath(
40
+ projectPath,
41
+ isDev,
42
+ false,
43
+ customTsconfigPath
44
+ );
38
45
  if (!await fs.pathExists(configPath)) {
39
- await createRseConfig(projectPath, githubUsername, isDev, overrides);
46
+ await createReliverseConfig(projectPath, githubUsername, isDev, overrides);
40
47
  } else {
41
48
  const content = (await fs.readFile(configPath, "utf-8")).trim();
42
49
  if (!content || content === "{}") {
43
- await createRseConfig(projectPath, githubUsername, isDev, overrides);
50
+ await createReliverseConfig(projectPath, githubUsername, isDev, overrides);
44
51
  } else {
45
- const validConfig = await readRseConfig(configPath, isDev);
52
+ const validConfig = await readReliverseConfig(configPath, isDev);
46
53
  if (!validConfig) {
47
- const fixed = await parseAndFixRseConfig(configPath, isDev);
54
+ const fixed = await parseAndFixReliverseConfig(configPath, isDev);
48
55
  if (!fixed) {
49
56
  relinka("warn", "Could not fix existing config. Using fallback defaults.");
50
57
  }
51
58
  }
52
59
  }
53
60
  }
54
- const mainConfig = await readRseConfig(configPath, isDev);
61
+ const mainConfig = await readReliverseConfig(configPath, isDev);
55
62
  if (!mainConfig) {
56
63
  relinka("warn", "Using fallback default config due to validation failure.");
57
- return { config: { ...DEFAULT_CONFIG_RSE }, mrse: results };
64
+ const fallbackConfig = { ...DEFAULT_CONFIG_RELIVERSE };
65
+ if (isDev) {
66
+ fallbackConfig.$schema = RSE_SCHEMA_DEV;
67
+ }
68
+ return { config: fallbackConfig, mrse: results };
58
69
  }
59
70
  if (isDev) {
60
71
  mainConfig.$schema = RSE_SCHEMA_DEV;
@@ -1,19 +1,20 @@
1
- import type { DeploymentService, RseConfig } from "../types/mod.js";
1
+ import type { ReliverseConfig } from "../schema/mod.js";
2
+ import type { DeploymentService } from "../types/mod.js";
2
3
  /**
3
4
  * Writes the given rseConfig to the specified config file (TypeScript or JSONC).
4
5
  * Performs an atomic write (using a temp file) and creates a backup of any existing config.
5
6
  * In dev mode, automatically builds a relative path to `sdk-mod.ts`.
6
7
  */
7
- export declare function writeRseConfig(configPath: string, config: RseConfig, isDev: boolean, skipInstallPrompt?: boolean): Promise<void>;
8
+ export declare function writeReliverseConfig(configPath: string, config: ReliverseConfig, isDev: boolean, skipInstallPrompt?: boolean): Promise<void>;
8
9
  /**
9
10
  * rse Config Creation (wrapper around config generator and fixer)
10
11
  */
11
- export declare function createRseConfig(projectPath: string, githubUsername: string, isDev: boolean, overrides: Partial<RseConfig>): Promise<void>;
12
+ export declare function createReliverseConfig(projectPath: string, githubUsername: string, isDev: boolean, overrides: Partial<ReliverseConfig>): Promise<void>;
12
13
  /**
13
14
  * Generates a rse config (rseConfig) by merging defaults, existing config, and overrides.
14
15
  * Writes the resulting config to disk (TypeScript or JSONC), optionally skipping install prompts in non-dev mode.
15
16
  */
16
- export declare function generateRseConfig({ projectName, frontendUsername, deployService, primaryDomain, projectPath, githubUsername, enableI18n, overwrite, isDev, configInfo, customOutputPath, customFilename, skipInstallPrompt, overrides, }: {
17
+ export declare function generateReliverseConfig({ projectName, frontendUsername, deployService, primaryDomain, projectPath, githubUsername, enableI18n, overwrite, isDev, configInfo, customOutputPath, customFilename, skipInstallPrompt, overrides, }: {
17
18
  projectName: string;
18
19
  frontendUsername: string;
19
20
  deployService: DeploymentService;
@@ -30,5 +31,5 @@ export declare function generateRseConfig({ projectName, frontendUsername, deplo
30
31
  customOutputPath?: string;
31
32
  customFilename?: string;
32
33
  skipInstallPrompt?: boolean;
33
- overrides: Partial<RseConfig>;
34
+ overrides: Partial<ReliverseConfig>;
34
35
  }): Promise<void>;