On Thu, 2008-08-28 at 19:59 +0200, Laurens Vets wrote: > Hello, > > >> When I log onto a linux host, and use "set" I can see that there a > >> couple of functions defined (test() for instance) in bash. How can I > >> read out these functions and use them in a perl script? > > > > You can't as they are bash functions, not Perl functions. > > There's no way to read them out like the environment variables? >
No. The environment variables are part of the OS, the bash functions are part of bash. Perl is not design to interface with any specific shell. You can read them by starting bash interactively, sending commands to its stdin and reading its stdout. See "Bidirectional Communication with Another Process" in perlipc and "Bidirectional Communication with Yourself" in perlipc -- Just my 0.00000002 million dollars worth, Shawn "Where there's duct tape, there's hope." Cross Time Cafe "Perl is the duct tape of the Internet." Hassan Schroeder, Sun's first webmaster -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/