Search code examples
manpage

Best way to author man pages?


What's the best way to author man pages? Should I write using the standard man macros, or is there some clever package available now that takes some kind of XML-ified source and can output man pages, HTML, ASCII, and what not?

Thanks


Solution

  • For my atinout program I have been using ronn which lets you write man pages in a very, very readable markdown like syntax. I am extremely happy with it.

    atinout(1) -- Send AT commands to modem, capturing the response
    ===============================================================
    
    ## SYNOPSIS
    
    `atinout` <input_file>|`-` <modem_device> <output_file>|`-`<br>
    `atinout` `--version`<br>
    `atinout` `--usage`<br>
    `atinout` `--help`<br>
    
    ## DESCRIPTION
    
    **Atinout** reads a list of AT commands. It sends those commands one by one
    to the modem, waiting for the final result code for the
    currently running command before continuing with the next command in
    the list. The output from the commands is saved.
    ...
    

    see the whole page here.