At 08:37 AM 7/9/02 -0500, David T-G wrote: >Peter, et al -- > >...and then Peter Scott said... >% >% At 09:33 AM 7/6/02 -0500, David T-G wrote: >% >I want to add to $ENV{'PATH'} in the parent process from my script. >% >Generally I know this isn't allowed, but I wonder if there's a way to do >% >it. >% >% No. It's a Unix FAQ and Perl can't do it any more than any other >% language. See 2.8 in http://www.faqs.org/faqs/unix-faq/faq/part2/ > >Yeah. I was hoping for a way to > > . myscript.pl bash > source myscript.pl tcsh > >or maybe > > `myscript.pl bash` > `myscript.pl tcsh` > >for that would make it work, but I haven't found anything yet.
sh-2.05a$ echo $PATH /usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/home/peter/bin:. sh-2.05a$ cat stage1 PATH=`stage2` export PATH sh-2.05a$ cat stage2 #!/usr/bin/perl -l print join ":" => qw(/sbin /usr/local/bin /etc); sh-2.05a$ . stage1 sh-2.05a$ echo $PATH /sbin:/usr/local/bin:/etc -- Peter Scott Pacific Systems Design Technologies http://www.perldebugged.com/ -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]