MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / refresh_strategy_label

Function refresh_strategy_label

crates/openshell-tui/src/app.rs:732–749  ·  view source on GitHub ↗
(strategy: i32)

Source from the content-addressed store, hash-verified

730}
731
732fn refresh_strategy_label(strategy: i32) -> &'static str {
733 match openshell_core::proto::ProviderCredentialRefreshStrategy::try_from(strategy)
734 .unwrap_or(openshell_core::proto::ProviderCredentialRefreshStrategy::Unspecified)
735 {
736 openshell_core::proto::ProviderCredentialRefreshStrategy::Static => "static",
737 openshell_core::proto::ProviderCredentialRefreshStrategy::External => "external",
738 openshell_core::proto::ProviderCredentialRefreshStrategy::Oauth2RefreshToken => {
739 "oauth2_refresh_token"
740 }
741 openshell_core::proto::ProviderCredentialRefreshStrategy::Oauth2ClientCredentials => {
742 "oauth2_client_credentials"
743 }
744 openshell_core::proto::ProviderCredentialRefreshStrategy::GoogleServiceAccountJwt => {
745 "google_service_account_jwt"
746 }
747 openshell_core::proto::ProviderCredentialRefreshStrategy::Unspecified => "unspecified",
748 }
749}
750
751fn mask_secret(value: &str) -> String {
752 let len = value.chars().count();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected