pub fn collapse_blank_lines(text: &str) -> String
Trim each line and collapse runs of blank lines to one.