[Feature] 编辑器支持 Annotate with Git Blame:行号旁显示修改日期 / 修改人,点击跳转到对应提交
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- git, typescript
- Área
- developer-experience, devtools
Línea de trabajo
Start by inspecting the editor’s line number context menu and the existing “使用 Git Blame 注释” implementation, then trace how Git History opens commit details. The issue describes the desired gutter annotations, hover details, click behavior, and context menu actions, but does not name files or tests. Done means blame annotations can be toggled per file, show date and author, expose commit details and navigation, and avoid full-file blame on every edit.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Problem to solve / 要解决的问题
当前 Lithe 已有“使用 Git Blame 注释”,但它打开的是一个弹框:
- 弹框里的 Blame 历史无法点击,无法定位 / 跳转到对应的 Git 提交历史,也看不到该提交的改动内容;
- 看完弹框要关掉再去 Git History 面板里手动找提交,流程是断的,排查“这行是谁、什么时候、为什么改的”很不方便。
Proposed solution / 建议方案
参考 IntelliJ IDEA 的 Annotate with Git Blame 实现:
- 入口:在编辑器行号区域右键菜单中增加
Annotate with Git Blame(与 IDEA 同名,便于 IDEA 用户找到),可开关,再次点击 / 选择 Close Annotations 关闭。 - 展示位置:开启后,在行号右侧、代码左侧增加一列注释(annotation gutter),按提交分块显示,每行 / 每块只显示两项,和 IDEA 一致,不需要短 hash:
- 修改日期(如
2026/6/23) - 修改人
- 未提交的行明确标注
Uncommitted changes
- 修改日期(如
- Hover 即看提交历史:鼠标移到某一行注释上,弹出该行的提交信息(commit、Author、Date、提交说明),不用点开、不用跳转就能先看一眼。
- 可点击跳转:点击某一行的注释,直接跳转到对应的 Git 提交历史 / 提交详情(提交信息、改动文件、diff),而不是只能看列表。
- 配套操作(参考 IDEA):
- 右键注释:Show History / 显示行历史、Show Diff、Copy Revision Number
- 性能:只对当前文件 / 可见范围做 blame,避免每次输入都全量重新 blame(之前 #343、#187 有过类似回归)。
现有弹框形式的“使用 Git Blame 注释”可保留作为补充,但不应是唯一的 Blame 查看方式;行内 Blame(inline blame)也不应替代 gutter 注释,两者可共存。
Target platform / 目标平台
macOS
Area / 模块
Editor / 编辑器
Priority / 优先级
P2 / 后续考虑:目前不着急,可安排到后续版本
Alternatives considered / 已考虑的替代方案
- 继续用弹框 + 手动去 Git History 里找提交:能用,但每次都要多步查找,且无法从行直接定位提交。
- 用“显示行历史”:只能看单行历史,无法像 Annotate 一样一眼扫过整个文件的修改分布。
Additional context / 补充信息
Lithe 版本:0.8.26
操作系统与架构:macOS Version 27.2.1 (Build 26B131) · arm64
环境信息:build: b963c8a · 2026-12-03;runtime: go1.27.4
- 参考:IntelliJ IDEA 右键行号菜单中的
Annotate with Git Blame(见截图 1),开启后注释列直接显示在行号旁。 - 现状:Lithe 行号右键菜单中的“使用 Git Blame 注释”(见截图 2)目前是弹框展示,弹框内历史不可点击、不可定位提交。
- 相关已关闭 Issue:#451、#1128 当时提的正是这个需求,现实现为弹框,未达到 IDEA 式 gutter 注释 + 点击跳转的效果,故新开此 Issue 作为后续跟进。
截图说明:
- IDEA 的
Annotate with Git Blame菜单 - Lithe 现有行号右键菜单,“使用 Git Blame 注释”
- IDEA 注释列只显示日期 + 修改人,hover 弹出对应提交的 commit / Author / Date / 提交说明
Checklist / 提交前检查
- I searched existing issues for duplicates. / 我已搜索现有 Issue,确认没有重复建议。
- Lenguaje dominante
- TypeScript
- Estrellas
- 1.8k
- Forks
- 151
- Merge medio
- 3 h 13 min
- PR fusionados (30 d)
- 614
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de 1lck/Lithe-IDEA
-
[Feature] 调试界面的图标提示显示快捷键Abiertoenhancement issue-form:feature review: medium
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
1lck/Lithe-IDEA#2678 ·
Los mantenedores suelen responder en 1 día
-
refactor review: high
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
1lck/Lithe-IDEA#2565 ·
Los mantenedores suelen responder en 1 día
-
area:ui enhancement P2 platform:cross-platform refactor review: high
Dificultad 1/5 Menos de una hora Aptitud para principiantes 84/100
1lck/Lithe-IDEA#2365 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
area:ai enhancement P2 review: high
Dificultad 5/5 Más de una semana Aptitud para principiantes 39/100
1lck/Lithe-IDEA#2660 ·
Los mantenedores suelen responder en 1 día
-
[Bug] Lithe 操作运行期间另一个程序写入的文本,本地历史有时记成用户(TestLocalHistoryTellsAnOperationsWriteFromAnotherPrograms 约 1/4 失败)Posiblemente ocupada @WhiteZeek la tomó hoy. Abiertoarea:editor bug P2 platform:macos review: high
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
1lck/Lithe-IDEA#2657 ·
Los mantenedores suelen responder en 1 día
Todos los issues de 1lck/Lithe-IDEA
Issues similares
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 92/100
Techiebutler/freeframe#687 ·
Los mantenedores suelen responder en 1 día
-
enhancement from-app needs-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
nightly-labs/openbot#23050 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
OHDSI/Data2Evidence#3846 ·
Los mantenedores suelen responder en 3 días
-
frontend: EditorDialog: Save & Apply on an empty or comment-only document reports success and applies nothingPosiblemente ocupada @shubhamrai9122-creator la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
kubernetes-sigs/headlamp#9086 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
openai/openai-node#3232 ·
Los mantenedores suelen responder en 1 día