[beta-1.72] backport #12411#12417
Merged
bors merged 1 commit intorust-lang:rust-1.72.0from Jul 30, 2023
Merged
Conversation
Git only assumes a submodule URL is a relative path if it starts with `./` or `../` [^1]. To fetch the correct repo, we need to construct an aboslute submodule URL. At this moment it comes with some limitations: * GitHub doesn't accept non-normalized URLs wth relative paths. (`ssh://git@github.com/rust-lang/cargo.git/relative/..` is invalid) * `url` crate cannot parse SCP-like URLs. (`git@github.com:rust-lang/cargo.git` is not a valid WHATWG URL) To overcome these, this patch always tries `Url::parse` first to normalize the path. If it couldn't, append the relative path as the last resort and pray the remote git service supports non-normalized URLs. See also rust-lang#12404 and rust-lang#12295. [^1]: <https://git-scm.com/docs/git-submodule>
Collaborator
|
r? @epage (rustbot has picked a reviewer for you, use r? to override) |
Collaborator
|
Member
Author
|
Should we backport this? I feel like yes. |
Contributor
Contributor
Contributor
Contributor
|
☀️ Test successful - checks-actions |
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Aug 1, 2023
…nglo [beta-1.72] Update cargo 1 commits in dd6536b8ed28f73c0e82089c72ef39a03bc634be..11ffe0e500346b26e3de1ba115482b4da586dfac 2023-07-18 14:02:13 +0000 to 2023-07-30 20:44:11 +0000 - [beta-1.72] backport rust-lang/cargo#12411 (rust-lang/cargo#12417) r? `@ghost`
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Beta backports:
ssh://#12411In order to make CI pass, the following PRs are also cherry-picked: