@kmlckj/licos-ai-cli 0.0.28 → 0.0.30
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/lib/__templates__/expo/.licosproj/scripts/dev_build.sh +3 -1
- package/lib/__templates__/expo/.licosproj/scripts/dev_run.sh +2 -2
- package/lib/__templates__/expo/.licosproj/scripts/prod_build.sh +2 -2
- package/lib/__templates__/expo/.licosproj/scripts/prod_run.sh +1 -1
- package/lib/__templates__/expo/.licosproj/scripts/server_dev_run.sh +1 -1
- package/lib/__templates__/expo/AGENTS.md +7 -5
- package/lib/__templates__/expo/README.md +5 -5
- package/lib/__templates__/expo/client/package.json +1 -1
- package/lib/__templates__/expo/client/scripts/install-missing-deps.js +11 -6
- package/lib/__templates__/expo/package.json +7 -4
- package/lib/__templates__/expo/pnpm-lock.yaml +5 -5
- package/lib/__templates__/expo/server/package.json +6 -6
- package/lib/__templates__/expo/template.config.js +12 -2
- package/lib/__templates__/nextjs/AGENTS.md +5 -3
- package/lib/__templates__/nextjs/README.md +3 -3
- package/lib/__templates__/nextjs/package.json +15 -13
- package/lib/__templates__/nextjs/pnpm-lock.yaml +21 -278
- package/lib/__templates__/nextjs/scripts/build.sh +1 -1
- package/lib/__templates__/nextjs/scripts/prepare.sh +1 -1
- package/lib/__templates__/nextjs/template.config.js +12 -2
- package/lib/__templates__/nuxt-vue/AGENTS.md +5 -3
- package/lib/__templates__/nuxt-vue/README.md +1 -1
- package/lib/__templates__/nuxt-vue/package.json +16 -12
- package/lib/__templates__/nuxt-vue/pnpm-lock.yaml +11 -406
- package/lib/__templates__/nuxt-vue/scripts/build.sh +1 -1
- package/lib/__templates__/nuxt-vue/scripts/prepare.sh +1 -1
- package/lib/__templates__/taro/.licosproj/scripts/deploy_build.sh +1 -1
- package/lib/__templates__/taro/.licosproj/scripts/dev_build.sh +1 -1
- package/lib/__templates__/taro/.licosproj/scripts/dev_run.sh +1 -1
- package/lib/__templates__/taro/AGENTS.md +7 -6
- package/lib/__templates__/taro/README.md +7 -7
- package/lib/__templates__/taro/package.json +3 -5
- package/lib/__templates__/taro/pnpm-lock.yaml +12 -211
- package/lib/__templates__/taro/server/package.json +1 -1
- package/lib/__templates__/taro/server/src/main.ts +2 -2
- package/lib/__templates__/vite/AGENTS.md +5 -3
- package/lib/__templates__/vite/README.md +7 -7
- package/lib/__templates__/vite/package.json +15 -13
- package/lib/__templates__/vite/pnpm-lock.yaml +5 -422
- package/lib/__templates__/vite/scripts/build.sh +1 -1
- package/lib/__templates__/vite/scripts/prepare.sh +1 -1
- package/lib/__templates__/vite/template.config.js +12 -2
- package/lib/cli.js +18 -10
- package/package.json +1 -1
|
@@ -12,6 +12,7 @@ CHECK_HASH_SCRIPT="$ROOT_DIR/check_hash.py"
|
|
|
12
12
|
check_command() {
|
|
13
13
|
if ! command -v "$1" &> /dev/null; then
|
|
14
14
|
echo "error:命令 $1 未找到,请先安装"
|
|
15
|
+
exit 1
|
|
15
16
|
fi
|
|
16
17
|
}
|
|
17
18
|
|
|
@@ -32,9 +33,10 @@ check_command "npm"
|
|
|
32
33
|
echo "==================== 安装项目依赖 ===================="
|
|
33
34
|
if [ ! -f "package.json" ]; then
|
|
34
35
|
echo "项目目录下无 package.json,不是合法的 Node.js 项目"
|
|
36
|
+
exit 1
|
|
35
37
|
fi
|
|
36
38
|
# 步骤 2.1/2.2:安装项目依赖
|
|
37
|
-
pnpm install --registry=https://registry.npmmirror.com
|
|
39
|
+
pnpm install --registry=https://registry.npmmirror.com --prefer-frozen-lockfile --prefer-offline --reporter=append-only
|
|
38
40
|
|
|
39
41
|
echo "检查根目录 post_install.py"
|
|
40
42
|
if [ -f "$PREVIEW_DIR/post_install.py" ]; then
|
|
@@ -129,10 +129,10 @@ start_expo() {
|
|
|
129
129
|
|
|
130
130
|
if [ "$offline" = "1" ]; then
|
|
131
131
|
( EXPO_OFFLINE=1 EXPO_NO_DEPENDENCY_VALIDATION=1 EXPO_PUBLIC_BACKEND_BASE_URL="$EXPO_PUBLIC_BACKEND_BASE_URL" EXPO_PACKAGER_PROXY_URL="$EXPO_PACKAGER_PROXY_URL" EXPO_PUBLIC_LICOS_PROJECT_ID="$EXPO_PUBLIC_LICOS_PROJECT_ID" \
|
|
132
|
-
nohup
|
|
132
|
+
nohup pnpm exec expo start --clear --port "$EXPO_PORT" 2>&1 | pipe_to_log "CLIENT" "$LOG_CLIENT_FILE" ) &
|
|
133
133
|
else
|
|
134
134
|
( EXPO_NO_DEPENDENCY_VALIDATION=1 EXPO_PUBLIC_BACKEND_BASE_URL="$EXPO_PUBLIC_BACKEND_BASE_URL" EXPO_PACKAGER_PROXY_URL="$EXPO_PACKAGER_PROXY_URL" EXPO_PUBLIC_LICOS_PROJECT_ID="$EXPO_PUBLIC_LICOS_PROJECT_ID" \
|
|
135
|
-
nohup
|
|
135
|
+
nohup pnpm exec expo start --clear --port "$EXPO_PORT" 2>&1 | pipe_to_log "CLIENT" "$LOG_CLIENT_FILE" ) &
|
|
136
136
|
fi
|
|
137
137
|
EXPO_PID=$!
|
|
138
138
|
disown $EXPO_PID 2>/dev/null || true
|
|
@@ -32,8 +32,8 @@ info "==================== 安装 Node 依赖 ===================="
|
|
|
32
32
|
info "开始安装 Node 依赖"
|
|
33
33
|
if [ -f "$ROOT_DIR/package.json" ]; then
|
|
34
34
|
info "进入目录:$ROOT_DIR"
|
|
35
|
-
info "正在执行:pnpm install"
|
|
36
|
-
(cd "$ROOT_DIR" && pnpm install --registry=https://registry.npmmirror.com) || error "Node 依赖安装失败"
|
|
35
|
+
info "正在执行:pnpm install --registry=https://registry.npmmirror.com --prefer-frozen-lockfile --prefer-offline"
|
|
36
|
+
(cd "$ROOT_DIR" && pnpm install --registry=https://registry.npmmirror.com --prefer-frozen-lockfile --prefer-offline --reporter=append-only) || error "Node 依赖安装失败"
|
|
37
37
|
else
|
|
38
38
|
warn "未找到 $ROOT_DIR/package.json 文件,请检查路径是否正确"
|
|
39
39
|
fi
|
|
@@ -51,4 +51,4 @@ kill_old_server
|
|
|
51
51
|
|
|
52
52
|
echo "启动 server 服务..."
|
|
53
53
|
cd "$SERVER_DIR"
|
|
54
|
-
NODE_ENV=development PORT="$SERVER_PORT"
|
|
54
|
+
NODE_ENV=development PORT="$SERVER_PORT" pnpm exec tsx watch ./src/index.ts 2>&1 | pipe_to_log "SERVER" "$LOG_SERVER_FILE"
|
|
@@ -52,6 +52,8 @@ Uniwind 官方文档:https://docs.uniwind.dev/llms.txt
|
|
|
52
52
|
|
|
53
53
|
## 如何进行静态校验(TSC + ESLint)
|
|
54
54
|
|
|
55
|
+
除非用户明确要求,修改代码时不要运行 `pnpm install`、`pnpm dev`、`pnpm build`、`pnpm lint:*`。平台预览和部署会负责依赖安装与启动。
|
|
56
|
+
|
|
55
57
|
```bash
|
|
56
58
|
# 对 client 和 server 目录同时进行校验
|
|
57
59
|
pnpm -w lint:all
|
|
@@ -221,18 +223,18 @@ export { default } from "@/screens/home";
|
|
|
221
223
|
|
|
222
224
|
| 目录 | 安装命令 | 说明 |
|
|
223
225
|
|------|----------|------|
|
|
224
|
-
| `client/` | `
|
|
225
|
-
| `server/` | `pnpm add <package>` | 使用 pnpm 管理后端依赖 |
|
|
226
|
+
| `client/` | `NPM_CONFIG_REGISTRY=https://registry.npmmirror.com pnpm --dir client exec expo install <package>` | Expo 会自动选择与 SDK 兼容的版本 |
|
|
227
|
+
| `server/` | `pnpm add --registry=https://registry.npmmirror.com <package>` | 使用 pnpm 管理后端依赖 |
|
|
226
228
|
|
|
227
229
|
```bash
|
|
228
230
|
# client 目录(Expo 项目)
|
|
229
|
-
|
|
231
|
+
NPM_CONFIG_REGISTRY=https://registry.npmmirror.com pnpm --dir client exec expo install expo-camera expo-image-picker
|
|
230
232
|
|
|
231
233
|
# server 目录(Express 项目)
|
|
232
|
-
cd server && pnpm add axios cors
|
|
234
|
+
cd server && pnpm add --registry=https://registry.npmmirror.com axios cors
|
|
233
235
|
```
|
|
234
236
|
|
|
235
|
-
**网络问题处理**:`
|
|
237
|
+
**网络问题处理**:`pnpm --dir client exec expo install` 可能因网络原因失败,失败时重试 2 次,仍失败则改用 `pnpm --dir client add --registry=https://registry.npmmirror.com` 安装
|
|
236
238
|
|
|
237
239
|
## Expo 开发规范
|
|
238
240
|
|
|
@@ -221,18 +221,18 @@ export { default } from "@/screens/home";
|
|
|
221
221
|
|
|
222
222
|
| 目录 | 安装命令 | 说明 |
|
|
223
223
|
|------|----------|------|
|
|
224
|
-
| `client/` | `
|
|
225
|
-
| `server/` | `pnpm add <package>` | 使用 pnpm 管理后端依赖 |
|
|
224
|
+
| `client/` | `NPM_CONFIG_REGISTRY=https://registry.npmmirror.com pnpm --dir client exec expo install <package>` | Expo 会自动选择与 SDK 兼容的版本 |
|
|
225
|
+
| `server/` | `pnpm add --registry=https://registry.npmmirror.com <package>` | 使用 pnpm 管理后端依赖 |
|
|
226
226
|
|
|
227
227
|
```bash
|
|
228
228
|
# client 目录(Expo 项目)
|
|
229
|
-
|
|
229
|
+
NPM_CONFIG_REGISTRY=https://registry.npmmirror.com pnpm --dir client exec expo install expo-camera expo-image-picker
|
|
230
230
|
|
|
231
231
|
# server 目录(Express 项目)
|
|
232
|
-
cd server && pnpm add axios cors
|
|
232
|
+
cd server && pnpm add --registry=https://registry.npmmirror.com axios cors
|
|
233
233
|
```
|
|
234
234
|
|
|
235
|
-
**网络问题处理**:`
|
|
235
|
+
**网络问题处理**:`pnpm --dir client exec expo install` 可能因网络原因失败,失败时重试 2 次,仍失败则改用 `pnpm --dir client add --registry=https://registry.npmmirror.com` 安装
|
|
236
236
|
|
|
237
237
|
## Expo 开发规范
|
|
238
238
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"main": "expo-router/entry",
|
|
5
5
|
"private": true,
|
|
6
6
|
"scripts": {
|
|
7
|
-
"check-deps": "
|
|
7
|
+
"check-deps": "pnpm exec depcheck",
|
|
8
8
|
"install-missing": "node ./scripts/install-missing-deps.js",
|
|
9
9
|
"lint": "tsc --noEmit; eslint ./ -f ./scripts/formatter.mjs --quiet",
|
|
10
10
|
"start": "expo start --web --clear",
|
|
@@ -16,7 +16,7 @@ try {
|
|
|
16
16
|
// 注意:depcheck 发现问题时会返回非零退出码,但这不是错误
|
|
17
17
|
let depcheckOutput;
|
|
18
18
|
try {
|
|
19
|
-
depcheckOutput = execSync('
|
|
19
|
+
depcheckOutput = execSync('pnpm exec depcheck --json', {
|
|
20
20
|
encoding: 'utf-8',
|
|
21
21
|
stdio: ['pipe', 'pipe', 'pipe'],
|
|
22
22
|
});
|
|
@@ -80,24 +80,29 @@ try {
|
|
|
80
80
|
const packagesToInstall = missingPackages.join(' ');
|
|
81
81
|
|
|
82
82
|
try {
|
|
83
|
-
execSync(`pnpm expo install ${packagesToInstall}`, {
|
|
83
|
+
execSync(`pnpm exec expo install ${packagesToInstall}`, {
|
|
84
84
|
stdio: 'inherit',
|
|
85
|
+
env: {
|
|
86
|
+
...process.env,
|
|
87
|
+
NPM_CONFIG_REGISTRY: 'https://registry.npmmirror.com',
|
|
88
|
+
npm_config_registry: 'https://registry.npmmirror.com',
|
|
89
|
+
},
|
|
85
90
|
});
|
|
86
91
|
|
|
87
92
|
console.log('\n所有缺失的依赖已安装完成');
|
|
88
93
|
} catch (installError) {
|
|
89
|
-
console.log('\nexpo install 失败,尝试使用
|
|
94
|
+
console.log('\nexpo install 失败,尝试使用 pnpm add --registry=https://registry.npmmirror.com...\n');
|
|
90
95
|
|
|
91
|
-
execSync(`
|
|
96
|
+
execSync(`pnpm add --registry=https://registry.npmmirror.com ${packagesToInstall}`, {
|
|
92
97
|
stdio: 'inherit',
|
|
93
98
|
});
|
|
94
99
|
|
|
95
|
-
console.log('\n所有缺失的依赖已通过
|
|
100
|
+
console.log('\n所有缺失的依赖已通过 pnpm 安装完成');
|
|
96
101
|
}
|
|
97
102
|
} catch (error) {
|
|
98
103
|
if (error.message.includes('depcheck')) {
|
|
99
104
|
console.error('depcheck 未安装或运行失败');
|
|
100
|
-
console.log('尝试运行:
|
|
105
|
+
console.log('尝试运行: pnpm add --registry=https://registry.npmmirror.com -D depcheck');
|
|
101
106
|
} else {
|
|
102
107
|
console.error('发生错误:', error.message);
|
|
103
108
|
}
|
|
@@ -6,10 +6,13 @@
|
|
|
6
6
|
"dev": "bash .licosproj/scripts/dev_run.sh",
|
|
7
7
|
"build": "bash .licosproj/scripts/prod_build.sh",
|
|
8
8
|
"start": "bash .licosproj/scripts/prod_run.sh",
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
9
|
+
"ensure:deps": "node -e \"const fs=require('fs'); const bins=['client/node_modules/.bin/expo','server/node_modules/.bin/tsx','server/node_modules/.bin/tsc']; process.exit(bins.every((p)=>fs.existsSync(p)||fs.existsSync(p+'.cmd'))?0:1)\" || pnpm install --registry=https://registry.npmmirror.com --prefer-frozen-lockfile --prefer-offline --reporter=append-only",
|
|
10
|
+
"prebuild": "pnpm run ensure:deps",
|
|
11
|
+
"predev": "pnpm run ensure:deps",
|
|
12
|
+
"preinstall": "node -e \"const ua=process.env.npm_config_user_agent||''; if(!ua.includes('pnpm')){console.error('Use pnpm to install dependencies.'); process.exit(1)}\"",
|
|
13
|
+
"lint:client": "pnpm --dir ./client lint",
|
|
14
|
+
"lint:server": "pnpm --dir ./server lint",
|
|
15
|
+
"lint:all": "pnpm --dir ./client lint && pnpm --dir ./server lint"
|
|
13
16
|
},
|
|
14
17
|
"dependencies": {},
|
|
15
18
|
"devDependencies": {},
|
|
@@ -263,8 +263,8 @@ importers:
|
|
|
263
263
|
server:
|
|
264
264
|
dependencies:
|
|
265
265
|
'@kmlckj/licos-platform-sdk':
|
|
266
|
-
specifier: 0.6.
|
|
267
|
-
version: 0.6.
|
|
266
|
+
specifier: 0.6.2
|
|
267
|
+
version: 0.6.2
|
|
268
268
|
cors:
|
|
269
269
|
specifier: ^2.8.5
|
|
270
270
|
version: 2.8.6
|
|
@@ -1321,8 +1321,8 @@ packages:
|
|
|
1321
1321
|
'@jridgewell/trace-mapping@0.3.31':
|
|
1322
1322
|
resolution: {integrity: sha512-zzNR+SdQSDJzc8joaeP8QQoCQr8NuYx2dIIytl1QeBEZHJ9uW6hebsrYgbz8hJwUQao3TWCMtmfV8Nu1twOLAw==}
|
|
1323
1323
|
|
|
1324
|
-
'@kmlckj/licos-platform-sdk@0.6.
|
|
1325
|
-
resolution: {integrity: sha512-
|
|
1324
|
+
'@kmlckj/licos-platform-sdk@0.6.2':
|
|
1325
|
+
resolution: {integrity: sha512-hnHnSjVpih6Z1DL2kGumql0WV7JClmwX9GulqTxfuNX42JHFbvzTq4xHUXtb37bFtFFMWWHzG7ascQFWrheb4w==}
|
|
1326
1326
|
|
|
1327
1327
|
'@langchain/core@1.1.17':
|
|
1328
1328
|
resolution: {integrity: sha512-g7/kcKbKEwNZSyyT7aT0utxn7wTOtKErqz0cL6VjrV4v/aOb9g+dKcfj17YkSm42YQmJp/rB2IXGc17vQPEBqA==}
|
|
@@ -7562,7 +7562,7 @@ snapshots:
|
|
|
7562
7562
|
'@jridgewell/resolve-uri': 3.1.2
|
|
7563
7563
|
'@jridgewell/sourcemap-codec': 1.5.5
|
|
7564
7564
|
|
|
7565
|
-
'@kmlckj/licos-platform-sdk@0.6.
|
|
7565
|
+
'@kmlckj/licos-platform-sdk@0.6.2': {}
|
|
7566
7566
|
|
|
7567
7567
|
'@langchain/core@1.1.17(openai@6.16.0(ws@8.19.0)(zod@4.3.6))':
|
|
7568
7568
|
dependencies:
|
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
"name": "server",
|
|
3
3
|
"private": true,
|
|
4
4
|
"type": "module",
|
|
5
|
-
"scripts": {
|
|
6
|
-
"build": "node build.js",
|
|
7
|
-
"dev": "bash ../.licosproj/scripts/server_dev_run.sh",
|
|
8
|
-
"preinstall": "
|
|
9
|
-
"start": "NODE_ENV=production PORT=${PORT:-5000} node dist/index.js",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"build": "node build.js",
|
|
7
|
+
"dev": "bash ../.licosproj/scripts/server_dev_run.sh",
|
|
8
|
+
"preinstall": "node -e \"const ua=process.env.npm_config_user_agent||''; if(!ua.includes('pnpm')){console.error('Use pnpm to install dependencies.'); process.exit(1)}\"",
|
|
9
|
+
"start": "NODE_ENV=production PORT=${PORT:-5000} node dist/index.js",
|
|
10
10
|
"lint": "tsc --noEmit"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@kmlckj/licos-platform-sdk": "0.6.
|
|
13
|
+
"@kmlckj/licos-platform-sdk": "0.6.2",
|
|
14
14
|
"cors": "^2.8.5",
|
|
15
15
|
"dayjs": "^1.11.19",
|
|
16
16
|
"dotenv": "^17.2.3",
|
|
@@ -57,9 +57,19 @@ const config = {
|
|
|
57
57
|
console.log('⊘ Skipping dependency install in test environment');
|
|
58
58
|
return;
|
|
59
59
|
}
|
|
60
|
+
if (_context.options?.skipInstall) {
|
|
61
|
+
console.log('⊘ Skipping dependency install because --skip-install was provided');
|
|
62
|
+
return;
|
|
63
|
+
}
|
|
60
64
|
|
|
61
65
|
const cmd = 'pnpm';
|
|
62
|
-
const args = [
|
|
66
|
+
const args = [
|
|
67
|
+
'install',
|
|
68
|
+
'--registry=https://registry.npmmirror.com',
|
|
69
|
+
'--prefer-frozen-lockfile',
|
|
70
|
+
'--prefer-offline',
|
|
71
|
+
'--reporter=append-only',
|
|
72
|
+
];
|
|
63
73
|
console.log(
|
|
64
74
|
`\nTriggering: ${cmd} ${args.join(' ')} (running in background)`,
|
|
65
75
|
);
|
|
@@ -94,7 +104,7 @@ const config = {
|
|
|
94
104
|
console.log(` Log file: ${logFile}`);
|
|
95
105
|
} catch (error) {
|
|
96
106
|
console.error('✗ Failed to trigger pnpm install:', error);
|
|
97
|
-
console.log(' You can manually run: pnpm install');
|
|
107
|
+
console.log(' You can manually run: pnpm install --registry=https://registry.npmmirror.com');
|
|
98
108
|
}
|
|
99
109
|
},
|
|
100
110
|
};
|
|
@@ -35,11 +35,13 @@
|
|
|
35
35
|
|
|
36
36
|
**仅允许使用 pnpm** 作为包管理器,**严禁使用 npm 或 yarn**。
|
|
37
37
|
**常用命令**:
|
|
38
|
-
- 安装依赖:`pnpm add <package>`
|
|
39
|
-
- 安装开发依赖:`pnpm add -D <package>`
|
|
40
|
-
- 安装所有依赖:`pnpm install`
|
|
38
|
+
- 安装依赖:`pnpm add --registry=https://registry.npmmirror.com <package>`
|
|
39
|
+
- 安装开发依赖:`pnpm add --registry=https://registry.npmmirror.com -D <package>`
|
|
40
|
+
- 安装所有依赖:`pnpm install --registry=https://registry.npmmirror.com`
|
|
41
41
|
- 移除依赖:`pnpm remove <package>`
|
|
42
42
|
|
|
43
|
+
除非用户明确要求,修改代码时不要运行 `pnpm install`、`pnpm dev`、`pnpm build`、`pnpm lint`、`pnpm ts-check`。平台预览和部署会负责依赖安装与启动。
|
|
44
|
+
|
|
43
45
|
## 开发规范
|
|
44
46
|
|
|
45
47
|
### Hydration 问题防范
|
|
@@ -164,13 +164,13 @@ export async function POST(request: Request) {
|
|
|
164
164
|
|
|
165
165
|
```bash
|
|
166
166
|
# ✅ 安装依赖
|
|
167
|
-
pnpm install
|
|
167
|
+
pnpm install --registry=https://registry.npmmirror.com
|
|
168
168
|
|
|
169
169
|
# ✅ 添加新依赖
|
|
170
|
-
pnpm add package-name
|
|
170
|
+
pnpm add --registry=https://registry.npmmirror.com package-name
|
|
171
171
|
|
|
172
172
|
# ✅ 添加开发依赖
|
|
173
|
-
pnpm add -D package-name
|
|
173
|
+
pnpm add --registry=https://registry.npmmirror.com -D package-name
|
|
174
174
|
|
|
175
175
|
# ❌ 禁止使用 npm 或 yarn
|
|
176
176
|
# npm install # 错误!
|
|
@@ -2,16 +2,19 @@
|
|
|
2
2
|
"name": "<%= appName %>",
|
|
3
3
|
"version": "0.1.0",
|
|
4
4
|
"private": true,
|
|
5
|
-
"scripts": {
|
|
6
|
-
"build": "bash ./scripts/build.sh",
|
|
7
|
-
"dev": "bash ./scripts/dev.sh",
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
"
|
|
5
|
+
"scripts": {
|
|
6
|
+
"build": "bash ./scripts/build.sh",
|
|
7
|
+
"dev": "bash ./scripts/dev.sh",
|
|
8
|
+
"ensure:deps": "node -e \"const fs=require('fs'); const bins=['node_modules/.bin/next','node_modules/.bin/tsx','node_modules/.bin/tsup','node_modules/.bin/eslint','node_modules/.bin/tsc']; process.exit(bins.every((p)=>fs.existsSync(p)||fs.existsSync(p+'.cmd'))?0:1)\" || pnpm install --registry=https://registry.npmmirror.com --prefer-frozen-lockfile --prefer-offline --reporter=append-only",
|
|
9
|
+
"prebuild": "pnpm run ensure:deps",
|
|
10
|
+
"predev": "pnpm run ensure:deps",
|
|
11
|
+
"preinstall": "node -e \"const ua=process.env.npm_config_user_agent||''; if(!ua.includes('pnpm')){console.error('Use pnpm to install dependencies.'); process.exit(1)}\"",
|
|
12
|
+
"lint": "eslint",
|
|
13
|
+
"start": "bash ./scripts/start.sh",
|
|
14
|
+
"ts-check": "tsc -p tsconfig.json"
|
|
12
15
|
},
|
|
13
16
|
"dependencies": {
|
|
14
|
-
"@kmlckj/licos-platform-sdk": "0.6.
|
|
17
|
+
"@kmlckj/licos-platform-sdk": "0.6.2",
|
|
15
18
|
"@aws-sdk/client-s3": "^3.958.0",
|
|
16
19
|
"@aws-sdk/lib-storage": "^3.958.0",
|
|
17
20
|
"@hookform/resolvers": "^5.2.2",
|
|
@@ -74,11 +77,10 @@
|
|
|
74
77
|
"@types/node": "^20",
|
|
75
78
|
"@types/pg": "^8.16.0",
|
|
76
79
|
"@types/react": "^19",
|
|
77
|
-
"@types/react-dom": "^19",
|
|
78
|
-
"eslint": "^9",
|
|
79
|
-
"eslint-config-next": "16.1.1",
|
|
80
|
-
"
|
|
81
|
-
"react-dev-inspector": "^2.0.1",
|
|
80
|
+
"@types/react-dom": "^19",
|
|
81
|
+
"eslint": "^9",
|
|
82
|
+
"eslint-config-next": "16.1.1",
|
|
83
|
+
"react-dev-inspector": "^2.0.1",
|
|
82
84
|
"shadcn": "latest",
|
|
83
85
|
"tailwindcss": "^4",
|
|
84
86
|
"tsup": "^8.3.5",
|