cloudcc-cli 2.3.6 → 2.3.7

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.
@@ -4,7 +4,7 @@ description: >-
4
4
  Defines how cloudcc-cli extends the `cc` command: argv shape, `bin/cc.js` entry
5
5
  (global flags, doctor/docs/init, action-level `-h`), `bin/index.js` Proxy routing,
6
6
  `src/version/listModuleCommands.js` for `--help`, per-resource `src/<resource>/index.js`
7
- dispatch, and MCP via `node` + `bin/mcp.js` (no `cc-mcp` bin). Release / changelog:
7
+ dispatch, and MCP via `cc-mcp` (→ `bin/mcp.js`) or `node` + absolute path to `bin/mcp.js`. Release / changelog in `README.md` must be **English only** (`# ReleaseV…` sections);
8
8
  ask whether to bump version; if not, only edit the existing `# ReleaseV…` for the
9
9
  current version in `README.md`. Use when adding or modifying CLI commands,
10
10
  subcommands, or modules in this repo, or when the user mentions cloudcc-cli
@@ -84,8 +84,8 @@ cloudcc <动作 action> <资源 resource> <其余参数 ...>
84
84
 
85
85
  ## MCP 与 `package.json` bin
86
86
 
87
- - **`package.json` 的 `bin`** 注册 **`cc`** 与 **`cloudcc`**(同一 `bin/cc.js`,Unix 上推荐 `cloudcc` 以免与系统 C 编译器 `cc` 冲突)、`cloudccCreate`、`cloudccBuild` 等,**不**注册 `cc-mcp`。
88
- - MCP 启动使用 **`node`** + **`cloudcc-cli` 包内 `bin/mcp.js` 的绝对路径**(全局安装路径可用 `$(npm root -g)/cloudcc-cli/bin/mcp.js` 拼接)。详见仓库 `README.md` / `src/project/docs/devguide.md`。
87
+ - **`package.json` 的 `bin`** 注册 **`cc`** 与 **`cloudcc`**(同一 `bin/cc.js`)、**`cc-mcp`**(→ `bin/mcp.js`)、`cloudccCreate`、`cloudccBuild` 等。
88
+ - MCP:**推荐**全局安装后 **`PATH` 上直接使用 `cc-mcp`**(与常见 `mcp.json` 里 `"command": "cc-mcp"` 一致);**亦可**用 **`node`** + **`bin/mcp.js` 绝对路径**(`$(npm root -g)/cloudcc-cli/bin/mcp.js`)。详见 `README.md` / `src/project/docs/devguide.md`。
89
89
 
90
90
  ---
91
91
 
@@ -123,7 +123,7 @@ cloudcc <动作 action> <资源 resource> <其余参数 ...>
123
123
  2. 新建或扩展 `src/<resource>/`,实现 `index.js` 及所需 `get`/`create`/… 子文件。
124
124
  3. 若有 `doc`,在 `src/<resource>/doc.js` 与 `docs/` 中维护说明;通过 `cloudcc doc <resource>` 可读。
125
125
  4. 更新 `src/version/listModuleCommands.js`:**`MODULE_KEYS_ORDER`**、**`MODULE_FOLDER`**,必要时 **`MODULE_HINT`**、**`RESOURCE_CN`**、**`describeActionLine`** 中的映射,保证 `cloudcc --help` 与 `cloudcc <action> -h` 正确。
126
- 5. 自测:`node bin/cc.js <动作> <resource> …`、`cloudcc --help` / `cloudcc --help`、`cloudcc <action> -h`;若 MCP 通过 `cliRunner` 调 **`cloudcc`**,确认参数顺序与文档一致。
126
+ 5. 自测:`node bin/cc.js <动作> <resource> …`、`cloudcc --help` / `cc --help`、`cloudcc <action> -h`;若 MCP 通过 `cliRunner` 调 **`cloudcc`**,确认参数顺序与文档一致。
127
127
 
128
128
  ---
129
129
 
@@ -131,10 +131,16 @@ cloudcc <动作 action> <资源 resource> <其余参数 ...>
131
131
 
132
132
  在**写入或更新开发日志**(`README.md` 中的 `# ReleaseV…`)时,**以后均照此执行**:
133
133
 
134
+ ### Release log language(变更日志语言 — 强制)
135
+
136
+ - **整节 `# ReleaseV…` 必须使用英文**:`#### Release Date`、`#### Release Scope`、`#### Release Content` 下的**所有列表与说明**均为英文;**不要**中英混写或整段中文。
137
+ - **原因**:`cc --version` 与注册表版本检查会从 README 解析这些块并在终端输出(`utils/readmeReleases.js` / `formatReleaseNotes.js`),英文便于统一展示与检索。
138
+ - **维护**:若某历史节仍为中文,在**编辑该节时**改为英文;不要求一次性翻完全部旧节,但**新增或修改的 Release 内容**一律英文。
139
+
134
140
  ### 必须先确认:是否升级版本号
135
141
 
136
142
  - **向用户询问**:本次是否需要**升级 `package.json` / `package-lock.json` 的版本号**(新一次发版)?
137
- - **若不需要升版**:**不要**修改 `package.json` 与 `package-lock.json` 的 `version`;只在 **`README.md` 里与当前 `package.json.version` 一致**的那一节 `# ReleaseV…`(例如已是 `# ReleaseV2.3.6`)中**增补或修订** `#### Release Content`(及必要时同一节内的日期说明),把新变更写进**现有版本**的日志里。
143
+ - **若不需要升版**:**不要**修改 `package.json` 与 `package-lock.json` 的 `version`;只在 **`README.md` 里与当前 `package.json.version` 一致**的那一节 `# ReleaseV…`(例如已是 `# ReleaseV2.3.7`)中**增补或修订** `#### Release Content`(及必要时同一节内的日期说明),把新变更写进**现有版本**的日志里;**增补/修订的正文仍须英文**(见「Release log language」)。
138
144
  - **若需要升版**:再执行下面的「升版 + 新节」流程。
139
145
 
140
146
  ### 升版 + 新 Release 节(仅在用户确认要发版时)
@@ -145,7 +151,7 @@ cloudcc <动作 action> <资源 resource> <其余参数 ...>
145
151
 
146
152
  2. **README.md 变更日志**
147
153
  - 在 **`README.md`** 中、**紧接「Usage Guide / CLI overview / MCP」等说明之后**、**旧版 Release 区块之上**,**插入新的** `# ReleaseV<主版本>.<次版本>.<补丁>` 一节(版本号与新的 `package.json` 一致)。
148
- - **新发布节全文使用英文**(标题、Release Date、Scope、Content 列表)。
154
+ - **本节内容与上文「Release log language」一致:全文英文**(含标题行、Date、Scope、Content)。
149
155
  - 结构建议:
150
156
  - `# ReleaseVx.y.z`
151
157
  - `#### Release Date: YYYY-M-D`
@@ -170,6 +176,6 @@ cloudcc <动作 action> <资源 resource> <其余参数 ...>
170
176
  3. **`permission` 命令语义**:由旧的 `cloudcc permission assign|add|remove`(资源不在第二位)改为符合全局约定的 **`cloudcc assign permission`、`cloudcc add permission`、`cloudcc remove permission`**;`cloudcc get permission` 保持不变。
171
177
  4. **`src/permission/index.js`**:与 `pagelayout` 等资源对齐,使用 **`cc` 子对象 + `main(action, argvs)`** 分发,去掉仅服务于旧写法的单参数 argv 分支。
172
178
  5. **`.claude/settings.json`** 等:允许/bash 规则从 `cloudcc permission:*` 调整为 `cloudcc assign permission:*` 等新模式(若仍使用 Claude 相关自动化)。
173
- 6. **`bin/cc.js` 全局能力**:`--help`/`help`、`doctor`、`docs`、`init`(别名 `create project`)、`cloudcc <action> -h`;`package.json` **不**注册 `cc-mcp`,MCP `node` + `bin/mcp.js` 路径。
179
+ 6. **`bin/cc.js` 全局能力**:`--help`/`help`、`doctor`、`docs`、`init`(别名 `create project`)、`cloudcc <action> -h`;MCP 通过 **`cc-mcp`** **`node` + `bin/mcp.js`** 启动。
174
180
 
175
181
  实现新功能时,**以本节与上文「命令行结构」为准**,勿再引入「首词为资源名」的并行体系。
package/README.md CHANGED
@@ -38,7 +38,21 @@ Run **`cloudcc --help`** or **`cc --help`** for the full command list: modules f
38
38
 
39
39
  ## MCP configuration
40
40
 
41
- `package.json` **does not** publish a `cc-mcp` binary. Start the MCP server with **Node** and the path to the bundled script:
41
+ After **`npm i -g cloudcc-cli`**, the package publishes a **`cc-mcp`** binary (→ `bin/mcp.js`). If your IDE **`mcp.json`** uses a command name (not `node` + `args`), use:
42
+
43
+ ```json
44
+ {
45
+ "mcpServers": {
46
+ "cloudcc-cli": {
47
+ "command": "cc-mcp"
48
+ }
49
+ }
50
+ }
51
+ ```
52
+
53
+ Ensure the npm global bin directory is on **`PATH`** (same as for `cloudcc` / `cc`). On Windows the shim is typically **`cc-mcp.cmd`**.
54
+
55
+ **Alternative** (explicit Node + script path):
42
56
 
43
57
  ```json
44
58
  {
@@ -51,12 +65,25 @@ Run **`cloudcc --help`** or **`cc --help`** for the full command list: modules f
51
65
  }
52
66
  ```
53
67
 
54
- After a global install, resolve the script path on macOS/Linux with:
68
+ Resolve the script path on macOS/Linux with:
55
69
 
56
70
  ```bash
57
71
  echo "$(npm root -g)/cloudcc-cli/bin/mcp.js"
58
72
  ```
59
73
 
74
+ # ReleaseV2.3.7
75
+
76
+ #### Release Date: 2026-4-1
77
+
78
+ #### Release Scope: Full
79
+
80
+ #### Release Content
81
+
82
+ - MCP
83
+ - **`cc-mcp`** (`package.json` → `bin/mcp.js`) is the recommended way to start the MCP server from IDE **`mcp.json`**; README **MCP configuration**, `src/project/docs/devguide.md` (section 5 and checklist), and **`.cursor/skills/cloudcc-cli-dev/SKILL.md`** are aligned, with **`node` + absolute path to `bin/mcp.js`** still documented as an alternative
84
+ - Documentation
85
+ - Release notes and **`package.json` / npm** version aligned to **2.3.7**
86
+
60
87
  # ReleaseV2.3.6
61
88
 
62
89
  #### Release Date: 2026-4-1
@@ -86,7 +113,7 @@ echo "$(npm root -g)/cloudcc-cli/bin/mcp.js"
86
113
  - CLI
87
114
  - Global commands: `doctor`, `docs`, `cloudcc help`, `init` (alias for `cloudcc create project`), clearer empty-argv / missing-resource hints, and `cloudcc <action> -h` to list resources for an action
88
115
  - Richer `cloudcc --help`: grouped modules, hints, and per-command descriptions via `src/version/listModuleCommands.js`
89
- - Removed `cc-mcp` from `package.json` `bin`; MCP is documented to use `node` and `bin/mcp.js`
116
+ - `cc-mcp` was temporarily removed from `package.json` `bin` in favor of `node` + `bin/mcp.js` only; **`cc-mcp` was restored in v2.3.6**; **v2.3.7** aligns README, project devguide, and **`cloudcc-cli-dev` SKILL** with **`"command": "cc-mcp"`** setup docs
90
117
  - Version checks compare to the registry; **`# ReleaseV…`** excerpts from **`README.md`** were shown together with that check (behavior refined in v2.3.6: notes only when an upgrade exists)
91
118
  - Terminal-friendly release notes: width-aware wrapping, aligned continuation lines, **`utils/formatReleaseNotes.js`** styling, and safe handling of inline `` `code` `` when wrapping
92
119
  - MCP
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cloudcc-cli",
3
- "version": "2.3.6",
3
+ "version": "2.3.7",
4
4
  "description": "cloudcc-cli",
5
5
  "author": "cloudcc",
6
6
  "license": "ISC",
@@ -13,7 +13,8 @@
13
13
  "cloudccCreate": "bin/project.js",
14
14
  "cloudccBuild": "bin/plugin.js",
15
15
  "cc": "bin/cc.js",
16
- "cloudcc": "bin/cc.js"
16
+ "cloudcc": "bin/cc.js",
17
+ "cc-mcp": "bin/mcp.js"
17
18
  },
18
19
  "scripts": {
19
20
  "test-cli-one": "node --test test/globalSelectList.cli.test.js",
@@ -18,7 +18,7 @@
18
18
  1. 安装 Node 与 npm,并切换 npm 源
19
19
  2. 安装 `cloudcc-cli` 全局依赖
20
20
  3. 安装 VS Code 与 CloudCC 插件
21
- 4. 配置本地 MCP(`node` 运行 `bin/mcp.js`)
21
+ 4. 配置本地 MCP(**`cc-mcp`** 或 `node` 运行 `bin/mcp.js`)
22
22
  5. 使用 CLI 创建模板项目并安装依赖
23
23
  6. 通过 CRM 获取开发者密钥、安全标记并写入 `cloudcc-cli.config.js`
24
24
  7. 视情况配置私有云与多环境参数
@@ -111,7 +111,19 @@ sudo npm ls -g --depth=0
111
111
 
112
112
  ## 5. 安装并配置本地 MCP
113
113
 
114
- 在支持 MCP 的开发工具中(如 Cursor),需要在 MCP 配置文件中添加(使用 `node` 启动包内脚本,**将 `args` 中的路径换成本机全局安装后的绝对路径**):
114
+ 在支持 MCP 的开发工具中(如 Cursor),全局安装 `cloudcc-cli` 并保证 npm 全局 **bin 在 `PATH` 中** 后,可在 MCP 配置里直接使用 **`cc-mcp`**(与 `package.json` `bin` 一致):
115
+
116
+ ```json
117
+ {
118
+ "mcpServers": {
119
+ "cloudcc-cli": {
120
+ "command": "cc-mcp"
121
+ }
122
+ }
123
+ }
124
+ ```
125
+
126
+ **备选**:使用 `node` 启动包内脚本(**将 `args` 中的路径换成本机全局安装后的绝对路径**):
115
127
 
116
128
  ```json
117
129
  {
@@ -127,7 +139,8 @@ sudo npm ls -g --depth=0
127
139
  说明:
128
140
 
129
141
  - `cloudcc-cli`:MCP 服务器标识,用于在工具中调用 CloudCC 相关能力
130
- - `command` / `args`:通过 Node 执行 `cloudcc-cli` 包内的 `bin/mcp.js`(全局安装后路径一般为 `$(npm root -g)/cloudcc-cli/bin/mcp.js`,请粘贴为绝对路径)
142
+ - **`cc-mcp`**:全局安装后由 npm 写入 PATH 的命令名,对应包内 `bin/mcp.js`
143
+ - **`node` + `args`**:路径一般为 `$(npm root -g)/cloudcc-cli/bin/mcp.js`(请粘贴为绝对路径)
131
144
 
132
145
  ---
133
146
 
@@ -352,7 +365,7 @@ module.exports = {
352
365
  - [ ] npm 源已切换到 `https://registry.npmmirror.com`
353
366
  - [ ] 已全局安装 `cloudcc-cli` 并验证
354
367
  - [ ] 已安装 VS Code 与 CloudCC 插件(或已按官方指引配置 Cursor)
355
- - [ ] MCP 已配置 `cloudcc-cli`(`node` + `bin/mcp.js`)
368
+ - [ ] MCP 已配置 `cloudcc-cli`(`cc-mcp` 或 `node` + `bin/mcp.js`)
356
369
  - [ ] 已通过 `cloudcc create project` 创建模板项目并成功 `npm i` + `npm run serve`
357
370
  - [ ] 已创建开发者账号并确认「代码管理」权限开启
358
371
  - [ ] 已获取开发者密钥与安全标记并正确配置 `cloudcc-cli.config.js`