in reply to Re^3: Cat'ing perl modules into single file script
in thread Cat'ing perl modules into single file script

I can think of a number of options, probably none of which you will like a lot, but one of which may be acceptable:

1/ Always use the latest version of the modules regardless of the combination of A and B that you have installed. It is natural for modules to evolve, but they should evolve in a controlled fashion so that later versions of a module do not break earlier scripts. Unit tests can check that that is the case. Just from a maintenance point of view the interface to a module should not change a lot over time because ensuring the correctness of use becomes problematic if it does change.

2/ Name the directory containing the module differently for the two scripts so that the scripts see different versions of the module.

3/ Always use the latest compatible version of the module and include a version number in the module name. Change the module name version number when there is a significant change the the interface. This is somewhat like option 1 with an escape clause for when you need to do a large overhaul of the module interface.


Perl reduces RSI - it saves typing
  • Comment on Re^4: Cat'ing perl modules into single file script