Merge pull request #54 from BapRx/feat/add-verbosity-repo-detection

feat: Return an error if the remote type cannot be detected
This commit is contained in:
2023-05-04 14:36:12 +02:00
committed by GitHub
3 changed files with 64 additions and 30 deletions

View File

@@ -72,12 +72,13 @@ fn find_repos(
let name = remote.name();
let url = remote.url();
let remote_type = match repo::detect_remote_type(&url) {
Some(t) => t,
None => {
Ok(t) => t,
Err(e) => {
warnings.push(format!(
"{}: Could not detect remote type of \"{}\"",
"{}: Could not handle URL {}. Reason: {}",
&path::path_as_string(&path),
&url
&url,
e
));
continue;
}