Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Jan 2006 22:05:54 +0200
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        SPYRIDON PAPADOPOULOS <SP373@student.apu.ac.uk>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: How to create a manual page in FreeBSD
Message-ID:  <20060112200554.GA1067@flame.pc>
In-Reply-To: <1137094538.8ba70fa0SP373@student.apu.ac.uk>
References:  <1137094538.8ba70fa0SP373@student.apu.ac.uk>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2006-01-12 19:35, SPYRIDON PAPADOPOULOS <SP373@student.apu.ac.uk> wrote:
> Hi all,
>
> Can anyone describe/give info, of how one can create a manual
> page for a custom program in FreeBSD. A manual page that would
> be accessible through the #man command. Is it possible?

Look at the existing manpages for examples, i.e.:

    /usr/src/bin/ls/ls.1

Then, you may get a good start for writing the groff source of a
manpage by copying and modifying one of the files:

$ ls -l /usr/share/examples/mdoc/*.?
-r--r--r--  1 root  wheel  - 3620 Jan 12 20:16 /usr/share/examples/mdoc/example.1
-r--r--r--  1 root  wheel  - 7658 Jan 12 20:16 /usr/share/examples/mdoc/example.3
-r--r--r--  1 root  wheel  - 3079 Jan 12 20:16 /usr/share/examples/mdoc/example.4
-r--r--r--  1 root  wheel  - 7757 Jan 12 20:16 /usr/share/examples/mdoc/example.9

The complete reference of all groff mdoc macros that you can use when
writing the document of the manpage is described in groff_mdoc(7):

    $ man groff_mdoc




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060112200554.GA1067>