Remove unnecessary spaces in headers

This commit is contained in:
Konstantin Nazarov 2021-07-10 22:47:07 +00:00
parent eacefbbbe8
commit e5291798cb
Signed by: knazarov
GPG key ID: 4CFE0A42FA409C22
2 changed files with 6 additions and 5 deletions

View file

@ -8,7 +8,8 @@ function parse_header(str, hnum, content) {
match(str, /#+/);
hnum = RLENGTH;
content = parse_line(substr(str, hnum + 1, length(str) - hnum ));
gsub(/^#+ */, "", str);
content = parse_line(str);
return "<h" hnum ">" content "</h" hnum ">";
}
if (match(body, /^[^\n]+\n=+$/)) {