On 11/14/06, siegfried <[EMAIL PROTECTED]> wrote:
Yeah: that is precisely the problem. The child inherits from the parent. Can I make the child manipulate the environment table in the parent? I don't think so. Please tell me I'm wrong.
No program wants its data changed without its knowledge and consent. The parent process in your case is no exception: If the child were able to change the parent's environment, the parent couldn't trust its own data. So each process has its own table of environment variables (copied from its parent's table at launch), and changes to the child's environment don't affect the parent. If you can get the parent process to cooperate, though, it is able to change its *own* data. The parent process could read the output of your Perl program, then use that output to set environment variables, or whatever you'd like it to do. (But it's generally easier to write a single Perl program to do your task, rather than to write a shell script that calls one or more other programs. Do you really need shell scripting when you have Perl?) Good luck with your project! --Tom Phoenix Stonehenge Perl Training -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>