(head: &GitHeadEvidence)
| 418 | } |
| 419 | |
| 420 | fn display_head(head: &GitHeadEvidence) -> String { |
| 421 | match head { |
| 422 | GitHeadEvidence::Attached { symref, oid } => format!("attached {symref} at {oid}"), |
| 423 | GitHeadEvidence::Detached { oid } => format!("detached at {oid}"), |
| 424 | GitHeadEvidence::Unborn { symref } => format!("unborn {symref}"), |
| 425 | GitHeadEvidence::MissingTarget { symref } => format!("missing target {symref}"), |
| 426 | GitHeadEvidence::Unknown { oid } => format!( |
| 427 | "unknown{}", |
| 428 | oid.as_ref() |
| 429 | .map(|oid| format!(" at {oid}")) |
| 430 | .unwrap_or_default() |
| 431 | ), |
| 432 | } |
| 433 | } |
| 434 | |
| 435 | #[derive(Clone, Debug, Eq, PartialEq)] |
| 436 | pub(crate) enum GuardOutcome { |
nothing calls this directly
no outgoing calls
no test coverage detected