返回 CodeWhale
provider.rs
根目录 / crates / tui / src / tui / setup / provider.rs
1 use codewhale_config::{StepEntry, StepStatus};
2
3 pub(super) fn step_status(provider_ready: bool) -> StepStatus {
4 if provider_ready {
5 StepStatus::Verified
6 } else {
7 StepStatus::NeedsAction
8 }
9 }
10
11 pub(super) fn step_entry(
12 provider_ready: bool,
13 checkpoint_version: &str,
14 result: impl Into<String>,
15 ) -> StepEntry {
16 StepEntry::new(step_status(provider_ready), true, checkpoint_version).with_result(result.into())
17 }
18
18 lines RUST