Repository navigation
fix(desktop): show new files' contents in Review and the Changes panel - #4415
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Review screen and the Changes panel show a new, untracked file's lines instead of "No text diff".
git_changesnow adds a diff that adds every line for each untracked text file (binary files and files over 1 MB are skipped, and the total stays under the 2 MB cap). The extra diffs are built only when the diff body is requested (summaryreads skip them).Changelog
New files an agent creates now show their contents in Review and the Changes panel, and can be commented on.
Testing
native.rs:a_new_file_patch_adds_every_line, anda_summary_counts_changes_without_the_diff_bodynow checks the new file's diff and that the oversized file is left out (CI runs them).cargo fmt --checkin the workspace andsrc-tauri,bun run check, comment and size lints.Closes #4389