Skip to content
This repository was archived by the owner on Sep 30, 2024. It is now read-only.
This repository was archived by the owner on Sep 30, 2024. It is now read-only.

Change git diffstat to (added, deleted) from (added, modified, deleted) #39390

@eseliger

Description

@eseliger

The Sourcegraph diffstat has historically been a little different than most code hosts render them: We have (added, modified, deleted), while most code hosts I know just have (added, deleted) and so does git, too. Our detection for “changed” is also pretty basic, it literally just counts - followed by +, so a - - + + diff replacing two lines would still be (2 added 0 modified 2 deleted). I think it would make things simpler and easier to understand if we dropped this concept of “changed” lines, which is underdefined anyways. With that we don’t have to rely on our very specific home-made library to parse (not that I want to switch but also we couldn’t) and we can likely take some short paths that save us a parse patch cycle, but mostly it just removes this confusing state. Git to me is red and green lines and that’s it.

Metadata

Metadata

Labels

4.0items under consideration for 4.0batch-changesIssues related to Batch Changesestimate/1d

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions