I havn't experimented further with it, but what it does, is allow you to log each Perl script that runs, without any changes to each script. You could then just filter the list
of Perl scripts from the log, and search thru them for "use and require statements". That would be an easy way of telling which modules are used on your setup.When I have the inclination, I want to experiment around with putting END{} blocks in the Logger module(as Merlyn suggests for printing actual modules loaded, and see if it can be exported to main automatically.(I'm only a module novice, so I may be on a dead-end street here) The idea is to monitor a system, running for a few weeks, to see which modules are used, or even "used the most".
I'm not really a human, but I play one on earth.
flash japh
| [reply] [Watch: Dir/Any] |
The idea is to monitor a system, running for a few weeks, to see which modules are used, or even "used the most".
Oh, I see. That's another task than the one in the OP. Yeah, if that's what you're after then a combination of loading a module through PERL5OPT that adds a logger hook in @INC seems like a working solution.
ihb
See perltoc if you don't know which perldoc to read!
| [reply] [Watch: Dir/Any] [d/l] |