gitoxide
gitoxide copied to clipboard
`gix_url::Url` `%`-encodes username in scp-like syntax
Current behavior 😯
This code generates the following output:
fn main() {
let url = gix_url::parse("[email protected]:org/repo.git".as_ref()).unwrap();
dbg!(&url);
println!("{}", url.to_bstring());
}
[src/main.rs:3:5] &url = Url {
scheme: Ssh,
user: Some(
"_git",
),
password: None,
host: Some(
"source.example.tld",
),
serialize_alternative_form: true,
port: None,
path: "org/repo.git",
}
%[email protected]:org/repo.git
Expected behavior 🤔
I'm not pretty sure, but Git appears not to decode %5Fgit back to _git.
This problem was originally reported as https://github.com/jj-vcs/jj/issues/6810.
Git behavior
No response
Steps to reproduce 🕹
No response