I have a distro with some cli scripts. One is a perl script and one is a c program. (I've been using c here and there and was very pleasantly surprised to see my Makefile.PL compile bin/code.c and take care of the rest without batting an eye. Wow.. I owe my predecessors..)

I've been embracing a practice of putting my documentation in separate .pod files. This helps maintenance- and gives that nice syntax highlighting in vim for pod- if you care about that.
Also, in my case with some c code, I can make a separate .pod file, since you likely can't embed pod in a .c source file.

Putting docs in .pod files works well for perl module files, but I am having some trouble getting the same to work for other stuff..

For example... if I have lib/MyModule.pm and lib/MyModule.pod, there's no problem. I can access the docs via 'man MyModule'.
But if I have bin/myscript and bin/myscript.pod , I have problems. It works if I place the doc in lib/myscript.pod - or if I place the doc inline inside bin/myscript

Thus, is the rule of thumb here that any documentation should be organized into a lib/ hierarchy inside a distro (or also at the root?) ?


In reply to Some clarification where pod files should reside in a distro by leocharre

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.