ronn
ronn copied to clipboard
roff: dots are not escaped correctly at beginning of line
While dots at the beginning of a line are escaped correctly, the check in the write method does not catch all cases where there are spaces in front of the dot in a NF:
$ man --warnings test/markdown_syntax.roff > /dev/null
<standard input>:1450: warning: macro `dot' not defined
(possibly missing space after `do')
$ groff -T ascii test/markdown_syntax.roff 2>/dev/null | grep dot
$
Here's a testcase:
- https://github.com/sometimesfood/ronn/tree/issues/46
- sometimesfood@30c0d64d2ca12992ee3fd3e83aa19146020fe64e
Here's a fix: https://github.com/rtomayko/ronn/pull/48
See #65. That may also fix this issue.
If you're still interested, I've fixed this case in my Ronn-NG fork at https://github.com/apjanke/ronn-ng/issues/17.