Open SEWeiTung opened 1 year ago
Hello @MaledongGit, can you please expand on this issue you are seeing? By "ORIGINAL" and "CURRENT" do you mean that the name of the GitHub user who owns the repository has been changed? Or is this a pull request to/from a fork and an upstream/original repository?
Hello @MaledongGit, can you please expand on this issue you are seeing? By "ORIGINAL" and "CURRENT" do you mean that the name of the GitHub user who owns the repository has been changed? Or is this a pull request to/from a fork and an upstream/original repository?
"ORIGINAL" here means "The original source name of the repository", "CURRENT" means the cloned (Forked) name of the repository.
e.g: Suppose I forked Nodejs.org and name it as "MaledongNode". The "ORIGINAL" name is "Nodejs", and "Current" name is "MaledongNode".
So the bug actually means:
When I submit a PR to Nodejs.org and it gets merged, and when I see it in the GitLens by clicking the PR in the GitLens windows, it opens up a 404 page instead of a real one.
As what you can see in the image, you can have a play with it directly in the latest version of VS and Git:
This is caused because of the difference between autolinks (what you have highlighted in yellow above) and the enrichment from the rich GitHub integration. Autolinks are "dumb" mappings, while the integration has context and can tell if the PR is from a fork.
We'll have to look into seeing if we can override the autolinks when they match with a connected remote.
In the meantime you should be able to workaround the issue, by setting the "true" repo as the "default" remote in GitLens -- e.g. right-click on the remote in the Remotes view and choose "Set as Default"
Hope that helps!
In the meantime you should be able to workaround the issue, by setting the "true" repo as the "default" remote in GitLens -- e.g. right-click on the remote in the Remotes view and choose "Set as Default"
Do u mean I should set "Default" to the original remote repo? I did it but no helps :(
But still say "Thank you" to @eamodio and @jkelroy :)
Same problem, if I forked a project and opened RP/issue link, it will go to my forked website's sub website.
Description
Steps to reproduce this bug:
Open any repository based on Git in the latest VS code.
Move your mouse onto a branch's PR:
Notice there are many link IDs like "#5166", and the yellow-circled part will raise a bug if you click it and open a page, a 404 page will be shown.
Reason
Compare the two links you'll see:
1) For the right one, the URL should be something like this:
2) For the wrong one, the URL:
Solution
To fix the URL's owner name (just as the other #5166 in the image, they are right in URL).
GitLens Version
13.6.0
VS Code Version
Version: 1.78.2 (system setup) Last PR: b3e4e68a0bc097f0ae7907b217c1119af9e03435 Date: 2023-05-10T14:39:26.248Z Electron: 22.5.2 Chromium: 108.0.5359.215 Node.js: 16.17.1 V8: 10.8.168.25-electron.0 OS: Windows_NT x64 10.0.19045 Is Sand-boxed: Yes
Git Version
2.34.0.windows.1
Logs, Screenshots, Screen Captures, etc
No response