B:BD[
4.53500] → [
4.53500:53622]
B:BD[
4.53622] → [
5.243:285]
∅:D[
5.285] → [
4.53657:53907]
B:BD[
4.53657] → [
4.53657:53907]
B:BD[
4.53907] → [
5.286:341]
B:BD[
5.341] → [
6.2649:2706]
∅:D[
6.2706] → [
4.54008:54130]
∅:D[
5.394] → [
4.54008:54130]
B:BD[
4.54008] → [
4.54008:54130]
if name.starts_with("http://") || name.starts_with("https://") {
debug!("unknown_remote, http = {:?}", name);
return Ok(RemoteRepo::Http(Http {
url: name.to_string(),
channel: channel.to_string(),
client: reqwest::ClientBuilder::new()
.danger_accept_invalid_certs(no_cert_check)
.build()?,
name: name.to_string(),
}));
}
if name.starts_with("ssh://") {
return if let Some(mut ssh) = ssh_remote(name) {
debug!("unknown_remote, ssh = {:?}", ssh);
Ok(RemoteRepo::Ssh(ssh.connect(name, channel).await?))
if let Ok(url) = url::Url::parse(name) {
let scheme = url.scheme();
if scheme == "http" || scheme == "https" {
debug!("unknown_remote, http = {:?}", name);
return Ok(RemoteRepo::Http(Http {
url,
channel: channel.to_string(),
client: reqwest::ClientBuilder::new()
.danger_accept_invalid_certs(no_cert_check)
.build()?,
name: name.to_string(),
}));
} else if scheme == "ssh" {
return if let Some(mut ssh) = ssh_remote(name) {
debug!("unknown_remote, ssh = {:?}", ssh);
Ok(RemoteRepo::Ssh(ssh.connect(name, channel).await?))
} else {
bail!("Remote not found: {:?}", name)
};