Just an idea:

Could you insert a coderef into @INC that would track which modules where loaded and record that info into a file or database. Then you run your shop as normal for a period of time and know what modules have been used. If you modules always use Strict maybe you could bastardize it to modify the @INC for you.

I'm not sure that is the perfect solution, but it might be a good way to see what modules actualy get used, it would require all the scripts to be run at least once though to ensure that there dependencies where captured and some things will have dynamic dependencies which will be trouble but you probably know what most of those are already.

Good luck and let us know if you find some spiffy solution.

Update: If you add

BEGIN { # look in cwd first unshift @INC => sub { warn "Loading $_[1]\n"; return undef; }; }
to the top of strict (still not sure this is the best place to put it, but it works as a kludge) then it prints all module uses to STDERR. You would of course want to modify it to do something more usefull in your case.


___________
Eric Hodges

In reply to Re: What modules are we actually using? by eric256
in thread What modules are we actually using? by cbrandtbuffalo

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.