-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
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
Allow compare page to look up base, head, own-fork, forkbase-of-head #11327
Conversation
Signed-off-by: Andrew Thornton <[email protected]>
Any screenshot? |
Signed-off-by: Andrew Thornton <[email protected]>
Codecov Report
@@ Coverage Diff @@
## master #11327 +/- ##
==========================================
+ Coverage 43.84% 43.96% +0.12%
==========================================
Files 613 613
Lines 87229 87345 +116
==========================================
+ Hits 38245 38403 +158
+ Misses 44262 44209 -53
- Partials 4722 4733 +11
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just an optional nit. LG-TM.
I think this should be 1.12. it's actually a bug fix really as it applies you to make PRs from the base repo directly rather than going to your fork first. The compare UI is awful and with the planned diff improvements we should overhaul it too. So I'm marking bug and placing back in 1.12. |
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
@a1012112796 so that's a different problem - if you can point me to exactly where the problem is I can see if I can hack it into here but it's not going to be in the same function. (I've found it before but can't remember where it was.) Frankly, the whole compare and diff page needs rewriting. It's a total mess, and the diff infrastructure does absolutely terrible things. I absolutely want this fix in 1.12 - I cannot refactor diff and get that in 1.12. Edit: I've prevented the 500 now |
I see, So It's okay to leave over this bug, It's not a big promblem. for me, I still expect separate pull request and fork function.which means user can make pull request from two repo which not necessary to have fork relation. the fork is only a fast way to copy repo not precondition to make pull request. Ah-ha, I'm dreaming again 😅 #11078 |
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
@a1012112796 I've prevented the 500. |
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
Signed-off-by: Andrew Thornton <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
huge imprufement for pulls :)
ping lgtm |
Following on from this pr we'll need to extend the API equivalent to allow for direct reference of repositories - however as they do not actually share a significant code base I think it's ok to do that separately. Of course, all of these endpoints are convoluted and tortuous and need to be significantly refactored in the next release. |
…o-gitea#11327) * Allow compare page to look up base, head, own-fork, forkbase-of-head Signed-off-by: Andrew Thornton <[email protected]> * as per @guillep2k Signed-off-by: Andrew Thornton <[email protected]> * Update routers/repo/compare.go * as per @guillep2k Signed-off-by: Andrew Thornton <[email protected]> * Rationalise the names a little Signed-off-by: Andrew Thornton <[email protected]> * Rationalise the names a little (2) Signed-off-by: Andrew Thornton <[email protected]> * Fix 500 with fork of fork Signed-off-by: Andrew Thornton <[email protected]> * Prevent 500 on compare different trees Signed-off-by: Andrew Thornton <[email protected]> * dotdotdot is perfectly valid in both usernames and repo names Signed-off-by: Andrew Thornton <[email protected]> * ensure we can set the head and base repos too Signed-off-by: Andrew Thornton <[email protected]> * ensure we can set the head and base repos too (2) Signed-off-by: Andrew Thornton <[email protected]> * fix lint Signed-off-by: Andrew Thornton <[email protected]> * only set headRepo == baseRepo if isSameRepo Signed-off-by: Andrew Thornton <[email protected]>
{:owner}/{:repo}:{:branch}
comparisons...
in the user name and repo name - fortunately these are banned from branch names by git.*Fix the 500 when comparing without a common history - just display that the PR cannot be made
Related #7759
Signed-off-by: Andrew Thornton [email protected]
Screenshots
Handle ... in usernames and reponames
On the root repo, with a different head proffer our fork