Creating man pages!!

I have a question..
How do you create a man page??
marcooAsked:
Who is Participating?
 
jlevieConnect With a Mentor Commented:
Man pages are written in a markup language, troff to be exact. You can write the pages directly with the embedded markup, or write the document in another form and use one of the xxx-to-man converters.

The markup language for troff is documented in the man pages for troff. Actual man pages use a troff macro to simplify the creation of the document and to provide a consistent appearance. The file containing the macros (/usr/lib/groff/tmac/tmac.an) contains comments that will tell you what each of the macros do. It's not that hard to to create a man page once you have a slight familiarity with the markup language and a similar existing man page to go by.

When you type "man troff" on Linux, you are effectively executing "groff -Tascii -man /usr/man/man1/troff.1 | more". Other unix implemetations (SGI for example) have a slightly different method of storing and retrieving man page data.
0
All Courses

From novice to tech pro — start learning today.