Daniel Kasak <mailto:[EMAIL PROTECTED]> wrote:
: Charles K. Clarkson wrote: : Managability. I can put all related stuff in 1 file. Then I'll : have main application logic in one main file, and other subs in : other files. It reduces clutter. Yes I realise that what I'm : asking for would have no difference to the Perl interpreter ... : that's the point. You can 'require' your files. use lib '.'; # Point to the path of your other files. require 'foo.pl'; require 'bar.pl'; require 'baz.pl'; If you have a long list of files, you could use a file to store your included files. includes.pl: use lib '.'; # Point to the path of your other files. require 'foo.pl'; require 'bar.pl'; require 'baz.pl'; __END__ main_script.pl: require 'includes.pl'; : And yes I know about modules / objects. I've made a couple of OS : modules myself. What I want here is part-way to a module. My : main issue is that I want of all my variables to be visible : without having to pass them in to each sub. Whoa, Bucko! Let's not be talking about those kinds of variables. I just had supper and I don't want it coming back up. Four out of five dentists recommend you avoid the kind of variables you have in your script. Still, sometimes its easier not to rewrite the entire script. Good Luck. HTH, Charles K. Clarkson -- Mobile Homes Specialist 254 968-8328 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>