Don't force ssh clone, it was stupid

This commit is contained in:
Thomas Forgione 2020-02-18 14:57:02 +01:00
parent d6bad5f61c
commit d0c0881271
1 changed files with 2 additions and 5 deletions

View File

@ -4,7 +4,7 @@ extern crate log;
use std::path::PathBuf; use std::path::PathBuf;
use std::process::exit; use std::process::exit;
use gclone::git::{clone, parse_url, parse_to_url, GCLONE_PATH}; use gclone::git::{clone, parse_url, GCLONE_PATH};
use gclone::{first_arg, Cache, Result}; use gclone::{first_arg, Cache, Result};
fn help() { fn help() {
@ -12,7 +12,6 @@ fn help() {
} }
fn main_result() -> Result<()> { fn main_result() -> Result<()> {
// Init beautylog // Init beautylog
beautylog::init(log::LevelFilter::Info).ok(); beautylog::init(log::LevelFilter::Info).ok();
@ -24,7 +23,7 @@ fn main_result() -> Result<()> {
} }
let url = if url.ends_with(".git") { let url = if url.ends_with(".git") {
&url[0..url.len() - 4] &url[0..url.len() - 4]
} else { } else {
&url &url
}; };
@ -37,8 +36,6 @@ fn main_result() -> Result<()> {
path.push(&owner); path.push(&owner);
path.push(&repo); path.push(&repo);
let url = parse_to_url(&server, &owner, &repo);
// Clone repository // Clone repository
info!("{} {}{}", "cloning", url, "..."); info!("{} {}{}", "cloning", url, "...");
clone(&url, &path)?; clone(&url, &path)?;