Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's offtopic, but man pages should really adopt a new format (e.g. markdown) instead of roff.

roff is a terrible way to write a document. Its format is ancient and not well documented. Its behavior is not consistent across different implementations. Worst of all, no proper i18n support.

There's a tool like roff2html, but again it's pretty sketchy in terms of reliability and i18n support. I wrote my own converter when I was translating OpenBSD manpages [1], but I hope more people recognize this issue. [1] https://github.com/euske/openssh-jman/blob/master/roff2html....



You can use scdoc(1) to produce man-pages from something that resembles a subset of markdown:

https://git.sr.ht/~sircmpwn/scdoc


PS: You can see an example of scdoc sources here:

https://github.com/kseistrup/timestamp/tree/master/src

The scdocs havde the extension .md because Microsoft Github thinks .sc is SuperCollider files, whatever that is. The .1 files are “compiled” from the .1.md sources.


I really like cht.sh

curl cht.sh/grep




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: