Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
How can I add man page entries for my own power tools?

Most (if not all) Linux commands have their man pages that describe their usage options etc. Can I create similar man page for my own bash scripts?

share|improve this question

marked as duplicate by manatwork, Kevin, sr_, Michael Mrozek Mar 19 '12 at 15:03

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

Apparently I miss-clicked downvote and now its set in stone, sorry about that. – ThorSummoner Oct 8 '15 at 16:59

Man pages are roff (see man 7 roff) formatted documents.

  • You can write it by hand.
  • You can use help2man to generate it from your script's help output.
  • You can write it in a markup language and use a dedicated tool to convert it to man:
share|improve this answer

Yes, you can. The man pages are written as nroff files.
The /usr/local/man directory is the location typically used for any locally installed packages/files.
You can look at examples by looking at the existing manpages, (which will likely need to be uncompressed first), also read man.
Presently many users prefer groff to nroff, man groff to get started

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.