@pubinfo/cli 2.1.10-beta.1 → 2.1.10
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.
- package/dist/{build-D-fWoV55.mjs → build-fbeKoowY.mjs} +3 -3
- package/dist/{commit-ChLh-iU3.mjs → commit-ivyMbCFK.mjs} +3 -3
- package/dist/{dev-3-XBwXFn.mjs → dev-COK5-AAB.mjs} +3 -3
- package/dist/{generate-BQHYDlQh.mjs → generate-Fcusbno0.mjs} +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.mjs +10 -10
- package/dist/{monorepo-d33M7XU0.mjs → monorepo-C2xK76ov.mjs} +1 -1
- package/dist/{preview-CLKqZdRX.mjs → preview-DiwjodFH.mjs} +1 -1
- package/dist/{setup-BL21Jlyx.mjs → setup-Dp6ZLQ8M.mjs} +3 -4
- package/dist/{upgrade-D4A0_AH0.mjs → upgrade-DP4f20uY.mjs} +1 -2
- package/package.json +11 -11
- /package/dist/{generate-BzEFFc8V.mjs → generate-zoyjAIve.mjs} +0 -0
- /package/dist/{icon-D9Q67P89.mjs → icon-C1SeWvgG.mjs} +0 -0
- /package/dist/{vite-L2nR7M6q.mjs → vite-BJWB50Xb.mjs} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as runVite } from "./vite-
|
|
2
|
-
import
|
|
1
|
+
import { t as runVite } from "./vite-BJWB50Xb.mjs";
|
|
2
|
+
import command from "./setup-Dp6ZLQ8M.mjs";
|
|
3
3
|
import { defineCommand, runMain } from "citty";
|
|
4
4
|
|
|
5
5
|
//#region src/commands/build.ts
|
|
@@ -9,7 +9,7 @@ var build_default = defineCommand({
|
|
|
9
9
|
description: "构建应用"
|
|
10
10
|
},
|
|
11
11
|
async run({ rawArgs }) {
|
|
12
|
-
await runMain(
|
|
12
|
+
await runMain(command);
|
|
13
13
|
await runVite("build", rawArgs);
|
|
14
14
|
}
|
|
15
15
|
});
|
|
@@ -39,13 +39,13 @@ var commit_default = {
|
|
|
39
39
|
const { createCzConfig, createGitMessage, runCzConfig, runNpx, runSimpleGitHooks, runGitMessage, lintMessage, runPrompt, isCommitlintEnabled, disableCommitlint, enableCommitlint } = await import("@pubinfo/commitlint");
|
|
40
40
|
const commitlintEnabled = await isCommitlintEnabled();
|
|
41
41
|
if (args.init) {
|
|
42
|
-
const cwd
|
|
42
|
+
const cwd = process.cwd();
|
|
43
43
|
if (!commitlintEnabled) {
|
|
44
|
-
if (disableCommitlint(cwd
|
|
44
|
+
if (disableCommitlint(cwd)) console.log("[pubinfo commit] 检测到 pubinfo.config 中已关闭 commitlint,已停用 git hooks。");
|
|
45
45
|
else console.log("[pubinfo commit] 检测到 pubinfo.config 中已关闭 commitlint,跳过初始化。");
|
|
46
46
|
return;
|
|
47
47
|
}
|
|
48
|
-
const pubinfoDir = `${cwd
|
|
48
|
+
const pubinfoDir = `${cwd}/.pubinfo`;
|
|
49
49
|
if (!fs.existsSync(pubinfoDir)) fs.mkdirSync(pubinfoDir);
|
|
50
50
|
const gitMessageStatus = createGitMessage();
|
|
51
51
|
const czConfigStatus = createCzConfig(pubinfoDir);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as runVite } from "./vite-
|
|
2
|
-
import
|
|
1
|
+
import { t as runVite } from "./vite-BJWB50Xb.mjs";
|
|
2
|
+
import command from "./setup-Dp6ZLQ8M.mjs";
|
|
3
3
|
import { defineCommand, runMain } from "citty";
|
|
4
4
|
|
|
5
5
|
//#region src/commands/dev.ts
|
|
@@ -9,7 +9,7 @@ var dev_default = defineCommand({
|
|
|
9
9
|
description: "启动应用"
|
|
10
10
|
},
|
|
11
11
|
async run({ rawArgs }) {
|
|
12
|
-
await runMain(
|
|
12
|
+
await runMain(command);
|
|
13
13
|
await runVite("dev", rawArgs);
|
|
14
14
|
}
|
|
15
15
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as ensureValidIdentifier, r as resolvePubinfoVersionFromApps, t as ensureMonorepoAppsDir } from "./generate-
|
|
1
|
+
import { n as ensureValidIdentifier, r as resolvePubinfoVersionFromApps, t as ensureMonorepoAppsDir } from "./generate-zoyjAIve.mjs";
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import { defineCommand } from "citty";
|
|
4
4
|
import { resolve } from "node:path";
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as citty from "citty";
|
|
2
2
|
|
|
3
3
|
//#region src/main.d.ts
|
|
4
|
-
declare const main:
|
|
4
|
+
declare const main: citty.CommandDef<citty.ArgsDef>;
|
|
5
5
|
//#endregion
|
|
6
6
|
//#region src/run.d.ts
|
|
7
7
|
declare const runMain: () => Promise<void>;
|
package/dist/index.mjs
CHANGED
|
@@ -3,22 +3,22 @@ import { fileURLToPath } from "node:url";
|
|
|
3
3
|
|
|
4
4
|
//#region package.json
|
|
5
5
|
var name = "@pubinfo/cli";
|
|
6
|
-
var version = "2.1.10
|
|
6
|
+
var version = "2.1.10";
|
|
7
7
|
var description = "CLI for Pubinfo";
|
|
8
8
|
|
|
9
9
|
//#endregion
|
|
10
10
|
//#region src/commands/index.ts
|
|
11
11
|
const _rDefault = (r) => r.default || r;
|
|
12
12
|
const commands = {
|
|
13
|
-
dev: () => import("./dev-
|
|
14
|
-
build: () => import("./build-
|
|
15
|
-
preview: () => import("./preview-
|
|
16
|
-
setup: () => import("./setup-
|
|
17
|
-
commit: () => import("./commit-
|
|
18
|
-
icon: () => import("./icon-
|
|
19
|
-
upgrade: () => import("./upgrade-
|
|
20
|
-
generate: () => import("./generate-
|
|
21
|
-
monorepo: () => import("./monorepo-
|
|
13
|
+
dev: () => import("./dev-COK5-AAB.mjs").then(_rDefault),
|
|
14
|
+
build: () => import("./build-fbeKoowY.mjs").then(_rDefault),
|
|
15
|
+
preview: () => import("./preview-DiwjodFH.mjs").then(_rDefault),
|
|
16
|
+
setup: () => import("./setup-Dp6ZLQ8M.mjs").then(_rDefault),
|
|
17
|
+
commit: () => import("./commit-ivyMbCFK.mjs").then(_rDefault),
|
|
18
|
+
icon: () => import("./icon-C1SeWvgG.mjs").then(_rDefault),
|
|
19
|
+
upgrade: () => import("./upgrade-DP4f20uY.mjs").then(_rDefault),
|
|
20
|
+
generate: () => import("./generate-Fcusbno0.mjs").then(_rDefault),
|
|
21
|
+
monorepo: () => import("./monorepo-C2xK76ov.mjs").then(_rDefault)
|
|
22
22
|
};
|
|
23
23
|
|
|
24
24
|
//#endregion
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as ensureValidIdentifier } from "./generate-
|
|
1
|
+
import { n as ensureValidIdentifier } from "./generate-zoyjAIve.mjs";
|
|
2
2
|
import { createRequire } from "node:module";
|
|
3
3
|
import { defineCommand } from "citty";
|
|
4
4
|
import { cp, mkdir, mkdtemp, readFile, rename, rm, writeFile } from "node:fs/promises";
|
|
@@ -7,8 +7,8 @@ import { existsSync, unlinkSync, writeFileSync } from "node:fs";
|
|
|
7
7
|
//#region src/utils/tsconfig.ts
|
|
8
8
|
function writeTsconfig(filePath) {
|
|
9
9
|
const require = createRequire(import.meta.url);
|
|
10
|
-
const resolveDeps = (name, path
|
|
11
|
-
return join(require.resolve(name), path
|
|
10
|
+
const resolveDeps = (name, path) => {
|
|
11
|
+
return join(require.resolve(name), path).replace(/\\/g, "/");
|
|
12
12
|
};
|
|
13
13
|
if (existsSync(filePath)) unlinkSync(filePath);
|
|
14
14
|
writeFileSync(filePath, `/* eslint-disable */
|
|
@@ -87,7 +87,6 @@ const command = defineCommand({
|
|
|
87
87
|
writeTsconfig(resolve(pubinfoDir, "tsconfig.app.json"));
|
|
88
88
|
}
|
|
89
89
|
});
|
|
90
|
-
var setup_default = command;
|
|
91
90
|
|
|
92
91
|
//#endregion
|
|
93
|
-
export {
|
|
92
|
+
export { command as default };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pubinfo/cli",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "2.1.10
|
|
4
|
+
"version": "2.1.10",
|
|
5
5
|
"description": "CLI for Pubinfo",
|
|
6
6
|
"exports": {
|
|
7
7
|
".": "./bin/pubinfo.mjs"
|
|
@@ -18,21 +18,21 @@
|
|
|
18
18
|
"node": "^20.19.0 || >=22.12.0"
|
|
19
19
|
},
|
|
20
20
|
"peerDependencies": {
|
|
21
|
-
"@pubinfo/vite": "2.1.10
|
|
21
|
+
"@pubinfo/vite": "2.1.10"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"cheerio": "^1.
|
|
25
|
-
"citty": "^0.
|
|
26
|
-
"execa": "^9.6.
|
|
27
|
-
"globby": "^
|
|
24
|
+
"cheerio": "^1.2.0",
|
|
25
|
+
"citty": "^0.2.0",
|
|
26
|
+
"execa": "^9.6.1",
|
|
27
|
+
"globby": "^16.1.0",
|
|
28
28
|
"pkg-types": "^2.3.0",
|
|
29
|
-
"@pubinfo/commitlint": "2.1.10
|
|
30
|
-
"
|
|
31
|
-
"
|
|
29
|
+
"@pubinfo/commitlint": "2.1.10",
|
|
30
|
+
"@pubinfo/shared": "2.1.10",
|
|
31
|
+
"create-pubinfo": "2.1.10"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@types/node": "^
|
|
35
|
-
"@pubinfo/vite": "2.1.10
|
|
34
|
+
"@types/node": "^25.2.2",
|
|
35
|
+
"@pubinfo/vite": "2.1.10"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"dev": "tsdown --watch",
|
|
File without changes
|
|
File without changes
|
|
File without changes
|