DeepSHPlugins
dsh-inline-diff 專案預覽
GITHUB / COMMUNITY PROJECT

dsh-inline-diff

UI 增強JavaScriptMIT

將編輯與寫入工具呼叫渲染為常開的雙欄 diff,可選語法配色與詞級高亮。

2 StarsJanEickholt 更新時間 2026-09-06
訪問 GitHub 倉庫
dsh-inline-diff 專案預覽
dsh-inline-diff 介面截圖dsh-inline-diff 介面截圖

專案介紹

中文

將編輯與寫入工具呼叫渲染為常開的雙欄 diff,可選語法配色與詞級高亮。

English

Renders edit and write tool calls as always-expanded side-by-side diffs, with optional syntax coloring and word-level highlighting.

專案資訊與收錄訊號

快照 2026-09-11
作者 / 組織
JanEickholt
倉庫
JanEickholt/dsh-inline-diff
GitHub Stars
2
Forks
0
開發語言
JavaScript
許可證
MIT
最近推送
2026-09-06
Manifest
資料中檢測到宣告

公開倉庫不自動等於可商用;許可證與當前相容性以原專案文件為準。Manifest 和資料評分不構成安裝安全認證。

資料評分

58/ 100
維護活躍
97
文件與實用資訊
85
生態關注度
14
安裝便捷訊號
100
專案宣告訊號
100

近 5 天仍在更新;README 含完整安裝與使用說明;關注度尚低(2)。

評分來自已有資料快照的五維模型,僅作瀏覽參考,不是實際使用評測或安全檢測結論。

安裝與使用

所有專案資料與許可均以對應 GitHub 倉庫為準。

dsh plugin --profile web add github:JanEickholt/dsh-inline-diff

複製命令不會自動執行。請先閱讀倉庫文件,確認環境要求與許可證。

專案截圖

倉庫 README

GitHub 原文

已儲存的倉庫文件快照;文件抓取時間未記錄,可能與上方目錄介紹處於不同版本。安裝前請核對當前倉庫說明。

儲存庫檔案保留原文,指令與授權文字不作自動改寫。

dsh-inline-diff

English | 简体中文

See every file your agent edits, right in the chat. No clicking required.

By default the DeepSeek Harness web GUI collapses each file edit into a tiny one-line row. This plugin replaces those rows with an always-open, side-by-side diff: old code on the left, new code on the right, additions in green, deletions in red, a colored edge bar on every changed row, a hover highlight that tracks the row under your cursor, and a +N −N summary for every file.

Withoutcollapsed rows, one click per file to see what changed
Withthe full diff right there, in the conversation

What it looks like

A typical edit: changed lines paired side by side, with the exact words that changed highlighted. Pairs are matched by similarity, so an insertion placed above an edited line (a comment, a blank line) does not steal the changed line's counterpart — unmatched lines simply render as plain additions or removals:

A diff card of an edit, with changed words highlighted

Words or whole lines

By default a changed line gets double highlighting: the row is tinted green/red, and on top of that the exact words that changed get a stronger highlight. Prefer it calmer? Open Settings → Plugins → Inline diff and pick *Lines only*. You keep the row tint but lose the word chips. The choice is saved in your DSH settings and survives restarts.

Line numbers

Every row carries a 1-based line number in a muted gutter, on both the old and the new side. The numbers come from the harness itself: when an edit settles, the plugin anchors each served hunk to its true position, and for hunks without an anchor the card reads the file through a fenced workspace route and locates the changed block verbatim. A hunk that cannot be located (a block appearing more than once, a drifted file, no host half) falls back to window-relative numbering from the hunk's first row, so a number always renders — but it may not be the file's true line. Prefer it cleaner? Pick *Off* under Settings → Plugins → Inline diff → Line numbers and the gutter disappears entirely. Like the other choices, this is saved and survives restarts.

Indentation

Edits often arrive indented with their surrounding code, which pushes the actual change toward the middle of the card. By default the diff strips the leading whitespace every non-empty line shares, so changes sit closer to the gutter; a small ⇤ N badge on the file header shows how many characters were removed. Prefer seeing the code as written? Pick *Keep* under Settings → Plugins → Inline diff and the original indentation stays. Like the highlighting choice, this is saved and survives restarts.

Syntax highlighting

Code rows are colored by a bundled highlight.js (the same language set the Solution Explorer sidebar uses), so edits read like an editor: keywords in your accent color, strings green, comments muted, and so on. The tokens read the same --shiki-token-* variables your GUI's code blocks render with, and the language is detected from the file's extension; unknown extensions stay plain. Prefer plain text? Pick *Off* under Settings → Plugins → Inline diff → Syntax highlighting. Like the other choices, this is saved and survives restarts.

dsh-stylevault compatible: its Colors panel overrides exactly those --shiki-token-* variables, so restyling your theme there restyles the diff cards too.

Themes

Every color on the card, from surfaces and text to borders and the green/red diff tints, is derived from your GUI's theme tokens (Settings → Appearance). The card follows light mode, dark mode, and any custom accent colors instead of a fixed palette. The syntax token colors ride the same system (the GUI's shiki code palette); before any theme variables exist they simply render as the card's plain text color.

The same compact edit under a custom theme — dsh-stylevault overrides exactly those token variables, so a restyle there restyles every diff card:

A compact diff card with a custom theme

Language

The settings card comes with English and Simplified Chinese text. It follows the GUI language picked under Settings → General → Language; when nothing is stored it follows your browser. A missing translation falls back to English.

Install

With the dsh CLI (easiest):

dsh plugin --profile web add github:JanEickholt/dsh-inline-diff

From GitHub (manual, same result):

  1. Add the plugin to your profile's package.json:
   "dsh-inline-diff": "github:JanEickholt/dsh-inline-diff"

then run pnpm install in the profile directory.

  1. Add it to your profile's cordis.patch.yml:
   - insert:
       - id: inline-diff
         name: 'dsh-inline-diff'
  1. Refresh the GUI page. Done. Every edit and file write now renders as an inline diff.

Manual: copy this repository into <profile>/node_modules/dsh-inline-diff/ and add the same patch row.

Contributing

Contributions of any kind are welcome: code, bug reports, docs, design ideas, screenshots, or just telling us what confused you. Open an issue or a pull request; nothing is too small.

Layout

The client ships as a single self-contained file because DSH loads it as one module. Its source of truth is src/, split per concern (line-diff.js, render.js, style.js, i18n.js, …). pnpm build (or pnpm test, which builds first) concatenates those blocks into lib/client.js. Edit files under src/, never lib/client.js directly. The two-tab indentation on code lines mirrors the module-loader wrapper the generated file is wrapped in; blank-line placement between blocks is added by the build.

About this project

This plugin was written by an AI coding agent (with a human steering it).

License

MIT

使用前核對

安裝步驟、相容版本與授權範圍以原專案當前文件為準。Stars 和評分是快照中的導航訊號。

安裝與排錯 · 專案問題反饋

同類專案