You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Idea: optional entity-level hunk labels (which function/class changed) via sem
#2173
delta already shows a hunk's function context from git's @@ header, which is a heuristic. Would there be interest in optional, accurate entity labels, showing precisely which function/class/method each change belongs to and whether it was added, modified, or removed?
This could be backed by sem, an open-source (MIT/Apache) entity-level code tool written in Rust. It resolves entities across 26 languages via tree-sitter and exposes a sem-core crate, so for a Rust project like delta it can integrate as a library rather than a subprocess (there's also a JSON CLI: sem diff --patch --format json).
Concretely it could power a precise "in function foo" / "modified method Bar::baz" label per hunk, or a short per-file semantic summary above the diff.
I maintain sem and would be happy to prototype this if there's appetite. Curious whether it fits delta's scope or is better as an external integration.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
delta already shows a hunk's function context from git's
@@header, which is a heuristic. Would there be interest in optional, accurate entity labels, showing precisely which function/class/method each change belongs to and whether it was added, modified, or removed?This could be backed by sem, an open-source (MIT/Apache) entity-level code tool written in Rust. It resolves entities across 26 languages via tree-sitter and exposes a
sem-corecrate, so for a Rust project like delta it can integrate as a library rather than a subprocess (there's also a JSON CLI:sem diff --patch --format json).Concretely it could power a precise "in function foo" / "modified method Bar::baz" label per hunk, or a short per-file semantic summary above the diff.
I maintain sem and would be happy to prototype this if there's appetite. Curious whether it fits delta's scope or is better as an external integration.
All reactions