dsh-claude-compat 0.8.0 â 0.8.1
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/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/package.json +1 -1
- package/src/index.js +5 -1
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<a href="README.zh-CN.md"><img src="https://img.shields.io/badge/đ_įŽäŊ䏿-įšæé
č¯ģ䏿-red?style=for-the-badge" alt="įŽäŊ䏿"></a>
|
|
9
9
|
<img src="https://img.shields.io/npm/dm/dsh-claude-compat?style=flat-square&label=downloads/month&color=brightgreen" alt="npm downloads/month">
|
|
10
10
|
<img src="https://img.shields.io/npm/dt/dsh-claude-compat?style=flat-square&label=total%20downloads&color=blue" alt="npm total downloads">
|
|
11
|
-
<img src="https://img.shields.io/badge/version-0.8.
|
|
11
|
+
<img src="https://img.shields.io/badge/version-0.8.1-blue?style=flat-square" alt="Version">
|
|
12
12
|
<img src="https://img.shields.io/badge/license-MIT-orange?style=flat-square" alt="License">
|
|
13
13
|
</p>
|
|
14
14
|
|
package/README.zh-CN.md
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<a href="README.md"><img src="https://img.shields.io/badge/đ_English-Click_me-red?style=for-the-badge" alt="English"></a>
|
|
9
9
|
<img src="https://img.shields.io/npm/dm/dsh-claude-compat?style=flat-square&label=downloads/month&color=brightgreen" alt="npm downloads/month">
|
|
10
10
|
<img src="https://img.shields.io/npm/dt/dsh-claude-compat?style=flat-square&label=total%20downloads&color=blue" alt="npm total downloads">
|
|
11
|
-
<img src="https://img.shields.io/badge/version-0.8.
|
|
11
|
+
<img src="https://img.shields.io/badge/version-0.8.1-blue?style=flat-square" alt="Version">
|
|
12
12
|
<img src="https://img.shields.io/badge/license-MIT-orange?style=flat-square" alt="License">
|
|
13
13
|
</p>
|
|
14
14
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-claude-compat",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.1",
|
|
4
4
|
"description": "DeepSeek Harness plugin: bridge Claude Code's .claude/ directories (project and ~/.claude: skills, commands, rules) into DSH native skill registry and message-stream rules injection.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
package/src/index.js
CHANGED
|
@@ -406,10 +406,14 @@ function registerRulesSection(ctx, config) {
|
|
|
406
406
|
const decision = await next();
|
|
407
407
|
if (decision.kind !== 'enter') return decision;
|
|
408
408
|
const present = (list) => list.some((m) => m?.source?.kind === 'claude-compat');
|
|
409
|
+
// Take one snapshot outside the loop: Session has no `events` property
|
|
410
|
+
// (dsh 0.1.2-rc.1) â snapshotEvents() is the public API. Indexing the
|
|
411
|
+
// snapshot by seq is stable and avoids re-materializing per node.
|
|
412
|
+
const events = agent.session.snapshotEvents();
|
|
409
413
|
const alreadyInjected = present(messages)
|
|
410
414
|
|| present(decision.messages)
|
|
411
415
|
|| agent.session.surface.nodes.some((seq) => {
|
|
412
|
-
const event =
|
|
416
|
+
const event = events[seq];
|
|
413
417
|
return event?.type === 'user/message'
|
|
414
418
|
&& event.data?.source?.kind === 'claude-compat';
|
|
415
419
|
});
|