@configjs/cli 1.1.16 → 1.1.17

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 (34) hide show
  1. package/dist/{angular-command-XN26G6L3.js → angular-command-WRBFDIV6.js} +8 -8
  2. package/dist/{angular-installer-FY43HE72.js → angular-installer-TKZDPFLD.js} +9 -1
  3. package/dist/angular-setup-QDTWXOB4.js +30 -0
  4. package/dist/check-5QZOSS2F.js +168 -0
  5. package/dist/{chunk-NYCK4R4K.js → chunk-56AR5ZW2.js} +361 -96
  6. package/dist/{chunk-TN27AX4L.js → chunk-5FBN3L7R.js} +797 -18
  7. package/dist/{chunk-FIB2J36N.js → chunk-5NXT5HCC.js} +142 -20
  8. package/dist/chunk-EDCNW4UO.js +92 -0
  9. package/dist/{chunk-UKEHW2LH.js → chunk-F3VNGA2S.js} +17 -3
  10. package/dist/{chunk-JYWGJJ4M.js → chunk-IY4KX4KL.js} +476 -28
  11. package/dist/chunk-V2IBYLVH.js +932 -0
  12. package/dist/chunk-VN4XTFDK.js +315 -0
  13. package/dist/cli.js +31 -21
  14. package/dist/{installed-D6CUYQM5.js → installed-DI77OQIT.js} +4 -4
  15. package/dist/{list-VZDUWV5O.js → list-HWRVKXWR.js} +4 -4
  16. package/dist/{nextjs-command-WKKOAY7I.js → nextjs-command-H5WRXK5R.js} +8 -9
  17. package/dist/{nextjs-installer-2ZC5IWJ6.js → nextjs-installer-UM3YQT5Z.js} +9 -2
  18. package/dist/{nextjs-setup-DYOFF72S.js → nextjs-setup-JIKPIJCX.js} +21 -9
  19. package/dist/{react-command-2T6IOTHB.js → react-command-XNOHP6WY.js} +8 -9
  20. package/dist/{remove-ZY3MLPGN.js → remove-AJK2IHVJ.js} +4 -4
  21. package/dist/{svelte-command-B2DNNQ5Z.js → svelte-command-Q7UBBWXP.js} +8 -8
  22. package/dist/svelte-installer-WLGID6Z2.js +105 -0
  23. package/dist/{svelte-setup-FWXLXJAC.js → svelte-setup-33E46IBT.js} +16 -5
  24. package/dist/{vite-installer-Y6VMFHIM.js → vite-installer-U7XUU3D7.js} +9 -2
  25. package/dist/{vite-setup-JRELX6K2.js → vite-setup-VO5BOI46.js} +16 -4
  26. package/dist/{vue-command-IOTC32AI.js → vue-command-FL6OQ6GV.js} +8 -9
  27. package/dist/{vue-installer-DGBBVF6F.js → vue-installer-BH2O2Y3M.js} +9 -2
  28. package/dist/{vue-setup-G44DLT2U.js → vue-setup-FK5QT7AY.js} +16 -4
  29. package/package.json +12 -4
  30. package/dist/angular-setup-Z6TCKNBG.js +0 -18
  31. package/dist/check-KNGZSCMM.js +0 -131
  32. package/dist/chunk-6GV4NKUX.js +0 -122
  33. package/dist/chunk-QPEUT7QG.js +0 -157
  34. package/dist/svelte-installer-EOSC3EP3.js +0 -65
@@ -1,157 +0,0 @@
1
- // src/utils/logger.ts
2
- import pc from "picocolors";
3
- var Logger = class {
4
- level = 1 /* INFO */;
5
- setLevel(level) {
6
- this.level = level;
7
- }
8
- debug(message, ...args) {
9
- if (this.level <= 0 /* DEBUG */) {
10
- console.log(pc.gray(`[DEBUG] ${message}`), ...args);
11
- }
12
- }
13
- info(message, ...args) {
14
- if (this.level <= 1 /* INFO */) {
15
- console.log(pc.cyan(`\u2139 ${message}`), ...args);
16
- }
17
- }
18
- success(message, ...args) {
19
- if (this.level <= 1 /* INFO */) {
20
- console.log(pc.green(`\u2713 ${message}`), ...args);
21
- }
22
- }
23
- warn(message, ...args) {
24
- if (this.level <= 2 /* WARN */) {
25
- console.warn(pc.yellow(`\u26A0\uFE0F ${message}`), ...args);
26
- }
27
- }
28
- error(message, ...args) {
29
- if (this.level <= 3 /* ERROR */) {
30
- console.error(pc.red(`\u2716 ${message}`), ...args);
31
- }
32
- }
33
- header(message) {
34
- if (this.level <= 1 /* INFO */) {
35
- console.log();
36
- console.log(pc.bold(pc.magenta(`\u25C6 ${message}`)));
37
- console.log();
38
- }
39
- }
40
- section(title) {
41
- if (this.level <= 1 /* INFO */) {
42
- console.log();
43
- console.log(pc.bold(pc.cyan(`\u25B8 ${title}`)));
44
- }
45
- }
46
- item(message, color = "gray") {
47
- if (this.level <= 1 /* INFO */) {
48
- const colorFn = pc[color];
49
- console.log(colorFn(` \u2022 ${message}`));
50
- }
51
- }
52
- dim(message) {
53
- if (this.level <= 1 /* INFO */) {
54
- console.log(pc.gray(` ${message}`));
55
- }
56
- }
57
- step(message) {
58
- if (this.level <= 1 /* INFO */) {
59
- console.log(pc.cyan(`
60
- \u2192 ${message}`));
61
- }
62
- }
63
- box(title, content) {
64
- if (this.level <= 1 /* INFO */) {
65
- const maxLength = Math.max(
66
- title.length,
67
- ...content.map((line) => line.length)
68
- );
69
- const border = "\u2500".repeat(maxLength + 4);
70
- console.log(pc.cyan(`\u250C${border}\u2510`));
71
- console.log(pc.cyan(`\u2502 ${title.padEnd(maxLength)} \u2502`));
72
- console.log(pc.cyan(`\u251C${border}\u2524`));
73
- content.forEach((line) => {
74
- console.log(pc.cyan(`\u2502 ${line.padEnd(maxLength)} \u2502`));
75
- });
76
- console.log(pc.cyan(`\u2514${border}\u2518`));
77
- }
78
- }
79
- };
80
- var logger = new Logger();
81
-
82
- // src/utils/logger-provider.ts
83
- var NoOpLogger = class {
84
- debug() {
85
- }
86
- info() {
87
- }
88
- warn() {
89
- }
90
- error() {
91
- }
92
- success() {
93
- }
94
- header() {
95
- }
96
- section() {
97
- }
98
- item() {
99
- }
100
- dim() {
101
- }
102
- step() {
103
- }
104
- box() {
105
- }
106
- };
107
- var LoggerProvider = class {
108
- currentLogger = new NoOpLogger();
109
- /**
110
- * Get the current logger instance
111
- * CLI commands should use the real logger
112
- * Core modules should use whatever is provided
113
- */
114
- getLogger() {
115
- return this.currentLogger;
116
- }
117
- /**
118
- * Set the active logger (typically called by CLI)
119
- * @param newLogger - The logger instance to use
120
- */
121
- setLogger(newLogger) {
122
- this.currentLogger = newLogger;
123
- }
124
- /**
125
- * Enable CLI logging (use the real logger)
126
- */
127
- enableCLILogging() {
128
- this.currentLogger = logger;
129
- }
130
- /**
131
- * Disable logging (use no-op logger)
132
- */
133
- disableLogging() {
134
- this.currentLogger = new NoOpLogger();
135
- }
136
- /**
137
- * Set the log level for the real logger
138
- */
139
- setLogLevel(level) {
140
- if (this.currentLogger === logger) {
141
- logger.setLevel(level);
142
- }
143
- }
144
- };
145
- var loggerProvider = new LoggerProvider();
146
- function getModuleLogger() {
147
- return loggerProvider.getLogger();
148
- }
149
- function initializeCLILogging() {
150
- loggerProvider.enableCLILogging();
151
- }
152
-
153
- export {
154
- logger,
155
- getModuleLogger,
156
- initializeCLILogging
157
- };
@@ -1,65 +0,0 @@
1
- import {
2
- checkPathExists
3
- } from "./chunk-FIB2J36N.js";
4
- import "./chunk-QPEUT7QG.js";
5
- import {
6
- getTranslations
7
- } from "./chunk-L4GX22RG.js";
8
- import "./chunk-QGM4M3NI.js";
9
-
10
- // src/cli/utils/svelte-installer.ts
11
- import { execSync } from "child_process";
12
- import { join } from "path";
13
- import pc from "picocolors";
14
- async function createSvelteProject(options, currentDir, language) {
15
- const t = getTranslations(language);
16
- const projectPath = join(currentDir, options.projectName);
17
- if (await checkPathExists(projectPath)) {
18
- throw new Error(
19
- t.vite.folderExists?.(options.projectName) || `Folder ${options.projectName} already exists`
20
- );
21
- }
22
- console.log();
23
- console.log(
24
- pc.cyan(`\u2728 ${t.svelte.creatingProject || "Creating Svelte project..."}`)
25
- );
26
- console.log();
27
- try {
28
- const templateSuffix = options.useTypeScript ? "" : "-js";
29
- const createCommand = `npm create svelte@latest ${options.projectName} -- --template skeleton${templateSuffix} --no-install`;
30
- execSync(createCommand, {
31
- cwd: currentDir,
32
- stdio: "inherit",
33
- shell: process.platform === "win32" ? "cmd.exe" : "/bin/sh"
34
- });
35
- console.log();
36
- console.log(
37
- pc.cyan(
38
- `\u{1F4E6} ${t.svelte.installingDependencies || "Installing dependencies..."}`
39
- )
40
- );
41
- console.log();
42
- execSync("npm install", {
43
- cwd: projectPath,
44
- stdio: "inherit"
45
- });
46
- console.log();
47
- console.log(
48
- pc.green(
49
- `\u2705 ${t.svelte.projectCreated || "Svelte project created successfully!"}`
50
- )
51
- );
52
- console.log();
53
- return projectPath;
54
- } catch (error) {
55
- console.error(
56
- pc.red(
57
- `\u274C Failed to create Svelte project: ${error instanceof Error ? error.message : String(error)}`
58
- )
59
- );
60
- throw error;
61
- }
62
- }
63
- export {
64
- createSvelteProject
65
- };