MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / message

Method message

atomic-cli/src/commands/auth.rs:419–438  ·  view source on GitHub ↗

Render an actionable, accurate error message for this issue. All messages point at registering an identity, since that is the single command that establishes a usable credential for a remote.

(&self)

Source from the content-addressed store, hash-verified

417 /// All messages point at registering an identity, since that is the single
418 /// command that establishes a usable credential for a remote.
419 fn message(&self) -> String {
420 match self {
421 CredentialIssue::NoIdentity => format!(
422 "Not authenticated for {REMEDY_PREFIX}: could not determine an \
423 identity from the remote URL, no --identity was given, and no \
424 default identity is set. Pass --identity <NAME> (see \
425 `atomic identity list`) or set a default with \
426 `atomic identity new <name> --set-default`. {REMEDY_SUFFIX}"
427 ),
428 CredentialIssue::ExplicitIdentityNotFound { name } => format!(
429 "Not authenticated for {REMEDY_PREFIX}: --identity '{name}' does \
430 not match any identity on this machine (see `atomic identity \
431 list`). {REMEDY_SUFFIX}"
432 ),
433 CredentialIssue::KeypairUnavailable { name } => format!(
434 "Not authenticated for {REMEDY_PREFIX}: could not load the signing \
435 key for identity '{name}'. {REMEDY_SUFFIX}"
436 ),
437 }
438 }
439}
440
441const REMEDY_PREFIX: &str = "this remote";

Callers 15

execute_reviseMethod · 0.45
runMethod · 0.45
synthesize_messageMethod · 0.45
count_commitsMethod · 0.45
write_commitMethod · 0.45
parse_commitFunction · 0.45
extract_commit_metadataFunction · 0.45
format_defaultMethod · 0.45

Calls

no outgoing calls