Skip to content

Commit b3ea1d5

Browse files
committed
chore(scripts): 支持无PR链接的变更条目标记解析与格式化
- 增加正则表达式匹配无PR链接的手动发布条目 - 在生成变更日志时支持无PR链接条目格式 - 为无PR链接条目生成无超链接的列表项文本 - 添加对应单元测试覆盖无PR链接条目解析与格式化 - 优化生成的变更日志内容兼容性与灵活性
1 parent dc6f560 commit b3ea1d5

3 files changed

Lines changed: 135 additions & 9 deletions

File tree

CHANGELOG.md

Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,20 @@ are listed; pre-releases are intentionally omitted.
1919
### Other
2020

2121
- chore(deps-dev): bump esbuild and tsx ([#174](https://github.com/lessweb/deepcode-cli/pull/174))
22+
- chore: 优化deepcode-self-refer skill
23+
- chore: 优化skill-digester skill
2224

2325
## [0.1.30](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.30)
2426

2527
`2026-06-15`
2628

29+
### Added
30+
31+
- enhance Windows MCP command quoting and add tests for cmd metacharacters
32+
- add plan mode skill and enhance shell init command tests
33+
- add support for implicit invocation control in skills
34+
- update default skill loading so enabledSkills can skip the built-in skills
35+
2736
### Fixed
2837

2938
- mcp: fix Windows MCP spawn double-quoting that breaks all MCP servers ([#164](https://github.com/lessweb/deepcode-cli/pull/164))
@@ -32,9 +41,17 @@ are listed; pre-releases are intentionally omitted.
3241

3342
`2026-06-09`
3443

44+
### Added
45+
46+
- implement bundled built-in skills
47+
- add docs/session-persistence.md
48+
- implement `enabledSkills` support in settings.json
49+
- add raw mode shortcut `ctrl+r`
50+
3551
### Other
3652

3753
- 修复提示输入的换行、光标定位与 busy 状态显示 ([#171](https://github.com/lessweb/deepcode-cli/pull/171))
54+
- @qorzj made their first contribution in https://github.com/lessweb/deepcode-cli/pull/171
3855

3956
## [0.1.28](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.28)
4057

@@ -49,6 +66,19 @@ are listed; pre-releases are intentionally omitted.
4966

5067
- extract OpenAI message converter from SessionManager ([#140](https://github.com/lessweb/deepcode-cli/pull/140))
5168

69+
### Other
70+
71+
- 升级bash tool,支持后台运行(`run_in_background`),可解决使用playwright测试场景下,启动server导致流程阻塞的问题
72+
- 修复bash tool多行参数的渲染问题,现在一定会显示LLM提供的description信息
73+
- Enhance cursor handling in PromptInput component to fix IME composition anchoring
74+
- 更新karpathy-guidelines.md,增加提示:`Apply these guidelines silently. Do not cite this document, its title, or guideline names in user-facing responses.`
75+
- Improve the Markdown underscore rendering
76+
- Add MCP tool name handling with API-safe names
77+
- Implement temperature support for settings.json
78+
- Agent Skills相关优化:
79+
- @dependabot[bot] made their first contribution in https://github.com/lessweb/deepcode-cli/pull/157
80+
- @Feiry-zZ made their first contribution in https://github.com/lessweb/deepcode-cli/pull/159
81+
5282
## [0.1.27](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.27)
5383

5484
`2026-06-01`
@@ -57,6 +87,10 @@ are listed; pre-releases are intentionally omitted.
5787

5888
- chore(deps): update ink-gradient to 4.0.1 ([#135](https://github.com/lessweb/deepcode-cli/pull/135))
5989
- chore: 更新API Key not found时的文本显示 ([#137](https://github.com/lessweb/deepcode-cli/pull/137))
90+
- 优化edit tool,取消返回findClosestMatch,直接用inferOldStringNotFoundReasonWithLLM生成提示信息
91+
- 改进系统提示词,引入[karpathy-guidelines](https://github.com/multica-ai/andrej-karpathy-skills),经验证对于复杂任务可显著提升成功率
92+
- @fym998 made their first contribution in https://github.com/lessweb/deepcode-cli/pull/135
93+
- @iamhmx made their first contribution in https://github.com/lessweb/deepcode-cli/pull/137
6094

6195
## [0.1.26](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.26)
6296

@@ -75,6 +109,9 @@ are listed; pre-releases are intentionally omitted.
75109
### Other
76110

77111
- chore(deps): 更新 ink 依赖到 7.0.4 版本 ([#125](https://github.com/lessweb/deepcode-cli/pull/125))
112+
- Edit 工具增强 — 支持空 old_string 的文件编辑,snippet 处理增强(full-file 支持 + 强制 snippet_id)
113+
- 快照机制增强 - 修复`/undo`恢复快照场景的已知问题
114+
- Agent+手动混合修改场景优化 - 基于快照机制检测到手动修改时,自动增加system prompt,可有效防止LLM无脑覆盖手动修改。
78115

79116
## [0.1.25](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.25)
80117

@@ -86,6 +123,7 @@ are listed; pre-releases are intentionally omitted.
86123
- ui: 会话列表支持 Delete 键删除会话 ([#114](https://github.com/lessweb/deepcode-cli/pull/114))
87124
- ui: 增加会话删除及相关UI重置功能 ([#119](https://github.com/lessweb/deepcode-cli/pull/119))
88125
- markdown 表格闭合边框渲染 + CJK/emoji 宽度适配 ([#115](https://github.com/lessweb/deepcode-cli/pull/115))
126+
- implement checkpoints store only explicit Write/Edit file paths
89127

90128
### Fixed
91129

@@ -99,6 +137,12 @@ are listed; pre-releases are intentionally omitted.
99137

100138
- 更新扩展命令菜单说明和帮助文档 ([#109](https://github.com/lessweb/deepcode-cli/pull/109))
101139

140+
### Other
141+
142+
- 实现权限机制,详见 [docs/permission.md](docs/permission.md)
143+
- @jeoor made their first contribution in https://github.com/lessweb/deepcode-cli/pull/102
144+
- @xinggitxing made their first contribution in https://github.com/lessweb/deepcode-cli/pull/114
145+
102146
## [0.1.24](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.24)
103147

104148
`2026-05-21`
@@ -117,6 +161,12 @@ are listed; pre-releases are intentionally omitted.
117161
- ui: 修正组件路径拼写错误 ([#93](https://github.com/lessweb/deepcode-cli/pull/93))
118162
- resolve CJK composition bug on iOS terminals (backspace packet splitting) ([#94](https://github.com/lessweb/deepcode-cli/pull/94))
119163

164+
### Other
165+
166+
- 新增`/undo`斜杠命令,同时实现了基于git的快照回滚机制
167+
- 适配七牛/火山引擎等deepseek模型时可能出现的tool call字段相关问题
168+
- @liante0904 made their first contribution in https://github.com/lessweb/deepcode-cli/pull/94
169+
120170
## [0.1.23](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.23)
121171

122172
`2026-05-19`
@@ -126,6 +176,11 @@ are listed; pre-releases are intentionally omitted.
126176
- 新增 `/raw` 命令交互与终端消息直出 ([#89](https://github.com/lessweb/deepcode-cli/pull/89))
127177
- notify: pass STATUS, FAIL_REASON, BODY, TITLE as env vars to notify hook ([#90](https://github.com/lessweb/deepcode-cli/pull/90))
128178

179+
### Other
180+
181+
- 修复Windows系统下Bash tool⽆法杀死进程组的问题
182+
- 实现Bash tool的超时机制,默认10分钟,可在ctrl+o界面调整
183+
129184
## [0.1.22](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.22)
130185

131186
`2026-05-18`
@@ -135,6 +190,14 @@ are listed; pre-releases are intentionally omitted.
135190
- add -p/--prompt flag to auto-submit prompt on launch ([#86](https://github.com/lessweb/deepcode-cli/pull/86))
136191
- Add Ctrl+O live process stdout viewer ([#75](https://github.com/lessweb/deepcode-cli/pull/75))
137192

193+
### Other
194+
195+
- 改进Edit tool在LLM出现参数`\`转义错误时的表现
196+
- 新增UpdatePlan tool和自带的plan-and-execute-skill提示词
197+
- 实现输入框中用`@`唤起file mention的功能
198+
- 实现`/command`斜杠命令
199+
- @whzp015258712145-hub made their first contribution in https://github.com/lessweb/deepcode-cli/pull/86
200+
138201
## [0.1.21](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.21)
139202

140203
`2026-05-16`
@@ -158,6 +221,10 @@ are listed; pre-releases are intentionally omitted.
158221
### Other
159222

160223
- style(DropdownMenu): 调整内边距优化下拉菜单布局 ([#73](https://github.com/lessweb/deepcode-cli/pull/73))
224+
- 为每个模型添加使用跟踪,并修复退出摘要(exit summary)表格
225+
- 改进Edit/Write tool,在一读多写失败的情况下提示LLM文件或片段已过时
226+
- 后端重构: move debug and error logging to common directory
227+
- @rock-solid-sites made their first contribution in https://github.com/lessweb/deepcode-cli/pull/56
161228

162229
## [0.1.20](https://github.com/lessweb/deepcode-cli/releases/tag/v0.1.20)
163230

@@ -181,3 +248,14 @@ are listed; pre-releases are intentionally omitted.
181248
- ui: 修正 reasoningEffort 显示逻辑 ([#63](https://github.com/lessweb/deepcode-cli/pull/63))
182249
- session: 修复系统消息可见性设置错误 ([#64](https://github.com/lessweb/deepcode-cli/pull/64))
183250
- filter image_url content from API messages for DeepSeek compatibility ([#51](https://github.com/lessweb/deepcode-cli/pull/51))
251+
252+
### Other
253+
254+
- 重构docs目录,分拆为普通文档目录(docs)和提示词模板目录(templates)
255+
- 重构后端代码,分拆出 `src/mcp``src/common` 目录
256+
- 优化系统提示词:删除DeepSeek不擅长的`ast-grep`相关内容;注入今天日期;给AI Agent一个名字(Deep Code),防止DeepSeek给自己脑补一个名字。
257+
- 实现完善的配置方案,参见:[docs/configuration.md](https://github.com/lessweb/deepcode-cli/blob/main/docs/configuration.md)
258+
- 优化`/model`的交互UI
259+
- 更新README文档
260+
- @dengmik-commits made their first contribution in https://github.com/lessweb/deepcode-cli/pull/48
261+
- @yuefengw made their first contribution in https://github.com/lessweb/deepcode-cli/pull/55

scripts/__tests__/generate-changelog.test.js

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,28 @@ test("parseReleaseEntries extracts entries from GitHub body", () => {
8787
assert.equal(entries[1].author, "bob");
8888
});
8989

90+
test("parseReleaseEntries handles entries without PR links (manual release notes)", () => {
91+
const body = [
92+
"* chore(deps-dev): bump esbuild and tsx by @dependabot[bot] in https://github.com/o/r/pull/174",
93+
"* chore: 优化deepcode-self-refer skill",
94+
"* chore: 优化skill-digester skill",
95+
].join("\n");
96+
97+
const entries = parseReleaseEntries(body);
98+
assert.equal(entries.length, 3);
99+
// entry with PR link
100+
assert.equal(entries[0].title, "chore(deps-dev): bump esbuild and tsx");
101+
assert.equal(entries[0].author, "dependabot[bot]");
102+
assert.equal(entries[0].prNumber, "174");
103+
// entries without PR link
104+
assert.equal(entries[1].title, "chore: 优化deepcode-self-refer skill");
105+
assert.equal(entries[1].author, null);
106+
assert.equal(entries[1].prUrl, null);
107+
assert.equal(entries[1].prNumber, null);
108+
assert.equal(entries[2].title, "chore: 优化skill-digester skill");
109+
assert.equal(entries[2].author, null);
110+
});
111+
90112
test("parseReleaseEntries handles empty body", () => {
91113
assert.deepEqual(parseReleaseEntries(""), []);
92114
assert.deepEqual(parseReleaseEntries(null), []);
@@ -121,6 +143,11 @@ test("formatEntry marks breaking changes", () => {
121143
assert.match(formatEntry(entry), /\*\*BREAKING\*\*/);
122144
});
123145

146+
test("formatEntry renders entry without PR link", () => {
147+
const entry = { title: "chore: optimize skill", prNumber: null, prUrl: null };
148+
assert.equal(formatEntry(entry), "- chore: optimize skill");
149+
});
150+
124151
// ── formatRelease ────────────────────────────────────────────────────────────
125152

126153
test("formatRelease groups entries by section", () => {

scripts/generate-changelog.js

Lines changed: 30 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,19 @@ const SECTION_ORDER = SECTIONS.map((section) => section.name);
5151
const STABLE_TAG_RE = /^v?(\d+)\.(\d+)\.(\d+)$/;
5252

5353
/**
54-
* Matches a GitHub "What's Changed" bullet, e.g.
54+
* Matches a GitHub "What's Changed" bullet with a PR link, e.g.
5555
*
5656
* fix(core): do a thing by @octocat in https://github.com/o/r/pull/42
5757
*/
5858
const ENTRY_RE = /^[*-]\s+(.+)\s+by\s+@([A-Za-z0-9-]+(?:\[bot\])?)\s+in\s+(https?:\/\/\S+\/pull\/(\d+))\s*$/;
5959

60+
/**
61+
* Matches a bullet without a PR link (manually added release entries), e.g.
62+
*
63+
* chore: optimize skill
64+
*/
65+
const SIMPLE_ENTRY_RE = /^[*-]\s+(.+?)\s*$/;
66+
6067
// ── Pure helpers (exported for testing) ──────────────────────────────────────
6168

6269
/**
@@ -86,13 +93,24 @@ export function parseReleaseEntries(body) {
8693
const entries = [];
8794
for (const line of (body || "").split(/\r?\n/)) {
8895
const match = ENTRY_RE.exec(line);
89-
if (!match) continue;
90-
entries.push({
91-
title: match[1].trim(),
92-
author: match[2],
93-
prUrl: match[3],
94-
prNumber: match[4],
95-
});
96+
if (match) {
97+
entries.push({
98+
title: match[1].trim(),
99+
author: match[2],
100+
prUrl: match[3],
101+
prNumber: match[4],
102+
});
103+
continue;
104+
}
105+
const simpleMatch = SIMPLE_ENTRY_RE.exec(line);
106+
if (simpleMatch) {
107+
entries.push({
108+
title: simpleMatch[1].trim(),
109+
author: null,
110+
prUrl: null,
111+
prNumber: null,
112+
});
113+
}
96114
}
97115
return entries;
98116
}
@@ -109,7 +127,10 @@ export function formatEntry(entry, cat = categorize(entry.title)) {
109127
if (breaking) {
110128
text = `**BREAKING** ${text}`;
111129
}
112-
return `- ${text} ([#${entry.prNumber}](${entry.prUrl}))`;
130+
if (entry.prNumber && entry.prUrl) {
131+
return `- ${text} ([#${entry.prNumber}](${entry.prUrl}))`;
132+
}
133+
return `- ${text}`;
113134
}
114135

115136
/** Render one release as a Markdown block. */

0 commit comments

Comments
 (0)