Skip to main content

Week 8 — Reuse Compare PR & On-Demand Diff

Meeting

Date: July 14, 2026
Attendees:

Absentees:

Summary

  1. Presented the updated design of the Reuse compare feature, now aligned with the existing codebase style.
  2. Discussed that the "Reuse compare" page doesn't need to pre-compute diff counts — instead, show a "View diff" button and compute the diff on demand only when the user clicks it.
  3. Discussed the diff approach: GNU diff -u which uses the Myers algorithm internally, written in C — efficient and works well with large files.
  4. Decided to remove the "Modified" line state and keep only "Added" and "Deleted" so the user can clearly see what changed without noise.

Progress

  • PR raised: Submitted PR #3717 for the Reuse compare feature.
  • File states: Each file falls into one of four states — Identical, Modified, Added, Deleted.
  • On-demand diff: Implemented diff calculation that runs only when the user clicks "View diff", avoiding unnecessary processing for files the user doesn't inspect.
  • File diff view: Color-coded view with:
    • Green — Added lines
    • Red — Deleted lines