Re: Calling a subroutine defined in another script file
- --- In email@example.com, "ruchika_27" <ruchika_27@y...>
> Inside a Perl script, can we use routines/functions defined inreturn
> another script file? I want to create a script that defines just
> some utility functions and want to use those utility functions
> inside another scripts? How can I do this? Can these routines
> error codes?http://www.perldoc.com/perl5.8.4/pod/perlsub.html
http://www.perldoc.com/perl5.8.4/pod/perlmod.html (See also...)
> How do we defines and use classes in Perl scripts?http://www.perldoc.com/perl5.8.4/pod/perltoot.html
Beware the overhead of working with classes in Perl -- i'm referring
to the syntactical scaffolding of indirection, not the performance
characteristics. Unless there are some clear inherent inheritance &
overloading structure in your module complex, it's easier && more
clean to base your design on the basic Perl module facility -- IMHO.
> Appreciate your help.BTW, why not use a utility like Make or Ant, possibily combined with
a Cron scheduler, for scripting automated builds? Just wondering...