qtjg/dsh-plugin-git-context ↗★ 0
@qtjg/dsh-plugin-git-context
A DeepSeek Harness plugin that exposes bounded Git status, diff, and log context to the model. 适合需要让大模型读取Git仓库状态、进行代码评审的开发人员。
Install
This plugin has no verified bundle, or compatibility checks failed. Read the repository notes first. Read the full README ↗
README
Read the full README ↗Configuration
| Field | Default | Description |
|---|---|---|
cwd | Harness process directory | Directory passed to Git as its working directory. |
maxBytes | 100000 | Maximum retained bytes for each ordinary Git output stream. The retained value is the stream tail when the limit is exceeded. |
maxLogEntries | 20 | Maximum number of commits accepted by git_context log. |
graceMs | 2000 | Process-tree termination grace period used by the subprocess service. |
reviewProvider | unset | Registered ctx.llm provider route used by git_review. Required for review. |
reviewModel | unset | Model id passed to the configured LLM provider. Required for review. |
reviewMaxTokens | 2000 | Maximum output tokens for one review call. |
reviewMaxDiffBytes | 50000 | Maximum diff bytes sent to the review model. |
The plugin validates positive integer limits at load time and rejects unsupported argument combinations before starting Git or an LLM call.
Usage
Ask the model for a repository view:
Use git_context with operation=status.
Use git_context with operation=diff and path=packages/core/tools/src/index.ts.
Use git_context with operation=log and limit=10.
Ask the model for an independent review:
Use git_review on the current unstaged changes.
Use git_review with path=src/index.ts and focus on security and data-loss risks.
git_review first obtains an unstaged diff through ctx.subprocess. If the diff is empty, it returns a clean result without making an LLM request. Otherwise it creates a Harness-native one-shot ctx.llm.stream call with a dedicated review system instruction and the diff delimited as untrusted data. The result includes the provider, model, review text, workspace, and whether the diff was truncated before the model call.