-
Notifications
You must be signed in to change notification settings - Fork 38.2k
Open
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitygitGIT issuesGIT issues
Milestone
Description
From @ashb in microsoft/vscode-pull-request-github#4551:
I have the following lines in my ~/.gitconfig:
[url "https://github.com/"]
insteadOf = "github:"
pushInsteadOf = "[email protected]:"
[url "[email protected]:"]
insteadOf = "gh:"
pushInsteadOf = "github:"
pushInsteadOf = "git://github.com/"(The effect is that I can do git clone github:user/public or git clone gh:user/private)
However I think the extension is getting confused about the gh: prefix and not reflecting my global git config.
For example, on such a private repo:
$ git config remote.origin.url
gh:user/private
$ git remote get-url origin
[email protected]:user/private
$ git remote show origin -n
* remote origin
Fetch URL: [email protected]:user/private
Push URL: [email protected]:user/private
When using the git extension API to get information about a repo that's been set up like this, the repository's remote doesn't have a meaningful url:

I don't see a way to resolve this URL to something meaningful using the git extension API. I think ideally the git extension API would resolve the fetch and push URLs instead of using the aliases.
Reactions are currently unavailable
Metadata
Metadata
Labels
feature-requestRequest for new features or functionalityRequest for new features or functionalitygitGIT issuesGIT issues