Skip to main content

parse_trailer_command_line_arg

Function parse_trailer_command_line_arg 

Source
pub fn parse_trailer_command_line_arg(
    raw: &str,
) -> Result<(String, String), TrailerArgParseError>
Expand description

Split a git commit --trailer argument into token and value.

The separator is the first : or = in the string (whichever comes first), matching Git’s parse_trailer_arg / git interpret-trailers --trailer.

§Errors

Returns TrailerArgParseError when neither separator appears.