Skip to main content

strip_comments_and_trim

Function strip_comments_and_trim 

Source
pub fn strip_comments_and_trim(input: &str) -> String
Expand description

Strip lines beginning with # (after any leading whitespace) and trim surrounding whitespace. Used by mkit commit when .mkit/COMMIT_EDITMSG is edited via $EDITOR.