Skip to main content

parse_alias

Function parse_alias 

Source
pub fn parse_alias(s: &str) -> Option<&str>
Expand description

Extract the path portion of an @secret:<path> alias. Returns Some(path) only when:

  • the string starts with ALIAS_PREFIX, and
  • the suffix after the prefix is non-empty.

None otherwise — including for the bare prefix ("@secret:") and for strings where the prefix appears mid-value.