Skip to content

Commit

Permalink
feat: support apple git in scan diagnostic (#7740)
Browse files Browse the repository at this point in the history
### Description

macOS can have either Apple git or regular git depending on source.
This PR adds support for the Apple git output format.


Closes TURBO-2646
  • Loading branch information
arlyon committed Mar 21, 2024
1 parent ada6815 commit fc8a05b
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions crates/turborepo-lib/src/diagnostics.rs
Expand Up @@ -189,6 +189,13 @@ impl Diagnostic for GitDaemonDiagnostic {
return;
};

// attempt to split out the apple git suffix
let version = if let Some((version, _)) = version.split_once(" (Apple") {
version
} else {
version
};

let Ok(version) = semver::Version::parse(version) else {
chan.failed("Failed to parse git version".to_string()).await;
return;
Expand Down

0 comments on commit fc8a05b

Please sign in to comment.