Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show diff on rename with diff changes #15338

Merged

Conversation

zeripath
Copy link
Contributor

@zeripath zeripath commented Apr 8, 2021

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix #15335

Signed-off-by: Andrew Thornton [email protected]

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix go-gitea#15335

Signed-off-by: Andrew Thornton <[email protected]>
@zeripath zeripath added type/bug topic/ui Change the appearance of the Gitea UI backport/v1.13 labels Apr 8, 2021
@zeripath zeripath added this to the 1.15.0 milestone Apr 8, 2021
zeripath added a commit to zeripath/gitea that referenced this pull request Apr 8, 2021
Backport go-gitea#15338

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix go-gitea#15335

Signed-off-by: Andrew Thornton <[email protected]>
zeripath added a commit to zeripath/gitea that referenced this pull request Apr 8, 2021
Backport go-gitea#15338

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix go-gitea#15335

Signed-off-by: Andrew Thornton <[email protected]>
@zeripath zeripath added the backport/done All backports for this PR have been created label Apr 8, 2021
@lunny
Copy link
Member

lunny commented Apr 8, 2021

We should detect if both .file.Addition and .file.Deletion is zero instead of it's a rename.

@GiteaBot GiteaBot added the lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. label Apr 8, 2021
@GiteaBot GiteaBot added lgtm/need 1 This PR needs approval from one additional maintainer to be merged. and removed lgtm/need 2 This PR needs two approvals by maintainers to be considered for merging. labels Apr 8, 2021
@6543
Copy link
Member

6543 commented Apr 8, 2021

I think (current state), will do it

@GiteaBot GiteaBot added lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. and removed lgtm/need 1 This PR needs approval from one additional maintainer to be merged. labels Apr 8, 2021
@techknowlogick
Copy link
Member

🚀

@techknowlogick techknowlogick merged commit f544414 into go-gitea:master Apr 8, 2021
techknowlogick pushed a commit that referenced this pull request Apr 8, 2021
Backport #15338

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix #15335

Signed-off-by: Andrew Thornton <[email protected]>

Co-authored-by: 6543 <[email protected]>
@zeripath zeripath deleted the fix-15335-show-rename-diff-changes branch April 8, 2021 19:36
techknowlogick pushed a commit that referenced this pull request Apr 8, 2021
Backport #15338

More recent versions of git have increased support for detection of renames meaning
that a rename with diff changes is now supported.

Although ParsePatch supports this - our templates do not and the simplest solution
is simply to show the diff.

Fix #15335

Signed-off-by: Andrew Thornton <[email protected]>

Co-authored-by: 6543 <[email protected]>
@go-gitea go-gitea locked and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
backport/done All backports for this PR have been created lgtm/done This PR has enough approvals to get merged. There are no important open reservations anymore. topic/ui Change the appearance of the Gitea UI type/bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add diff support for renamed/copied file changes on commit page
6 participants