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
Adds support of URL-like git ssh syntax #7509
Conversation
…tocols git supports two kinds of addresses, URL-like: ssh://[user@]server/project.git and scp-like: [user@]server:project.git This fix adds support of URL-like addresses
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.
Thanks for the PR! 🎉
# URL-like syntax | ||
self.assertEqual('ssh://git@github.com:2222/conan-io/conan.git', | ||
SCMBase._remove_credentials_url( | ||
'ssh://git@github.com:2222/conan-io/conan.git')) |
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.
Add a test to check that we are actually removing the password:
self.assertEqual('ssh://git@github.com:2222/conan-io/conan.git',
SCMBase._remove_credentials_url(
'ssh://git:passwd@github.com:2222/conan-io/conan.git'))
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.
LGTM! Thanks!
Changelog: Fix: Adds support of URL-like git ssh syntax.
Docs: omit
This PR fixes adds support of URL-like addresses mentioned #5833 (as for me, it was a regression introduced in #4207)
According to https://git-scm.com/book/en/v2/Git-on-the-Server-The-Protocols git supports two kinds of addresses, URL-like: ssh://[user@]server/project.git and scp-like: [user@]server:project.git
develop
branch, documenting this one.#PYVERS: Macos@py27, Windows@py36, Linux@py27
closes #5833