Skip to content

Conversation

m1guelpf
Copy link

@m1guelpf m1guelpf commented May 31, 2017

In my ssh config if specified that all connections with github should use the github.com domain. So when cloning a repo I can type:

git clone git@github:paulirish/git-open.git

or

git clone github:paulirish/git-open.git

instead of

git clone git@github.com:paulirish/git-open.git

This PR contains a fix for repos that have been cloned without specifying the github domain.

paulirish
paulirish previously approved these changes May 31, 2017
Copy link
Owner

@paulirish paulirish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

im looking forward to this script being ported to python. :)

@m1guelpf
Copy link
Author

@paulirish Updates?

@paulirish
Copy link
Owner

@m1guelpf can you add a test?

@derimagia
Copy link
Collaborator

I think if we use git ls-remote for grabbing the remote that would solve this, see the comment I added while implementing this:

# @TODO ls-remote will also expand "insteadOf" items `giturl=$(git ls-remote --get-url $remote)``

Just need to double check when the method of grabbing the remote was added in git since i know it's semi-new but I think it's probably safe at this point.

@derimagia
Copy link
Collaborator

Should be all fixed in #115

@derimagia derimagia closed this Feb 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants