in reply to Can i combine all the .PM's and main script into one file to create a distribution ?

In theory, with reasonably well-behaved modules, you can put all the code in the same file, provided you put all the modules in in the right order. Note that a use Module::Name arguments; statement also calls Module::Name->import( arguments ) so you'd have to replace the use statements with import() calls.

There might be issues with modules that use tricks in BEGIN blocks, or rely on being called during a BEGIN block.

As a side note, have you seen PAR?

  • Comment on Re: Can i combine all the .PM's and main script into one file to create a distribution ?
  • Select or Download Code