in reply to passing a parameter to an outside program

There are many ways to do this. Here are a few not yet mentioned:

envpass.pl:

#!/usr/bin/perl -w use strict; #set environment variables $ENV{FOOBAR} = 10000; #Set package level variables package manic; our $vroom = 10097; #You can use Data::Dumper package main; use Data::Dumper; my $foobie = 19897; open(H,qq|>junk.dat|) or die $!; print H Data::Dumper->Dump([$foobie],[qw[foobie]]); close(H); 1;

envpass2.pl

#!/usr/bin/perl -w use strict; do 'envpass.pl'; print $ENV{FOOBAR}; print $manic::vroom; #read in that data dumper stuff my $stuff = `cat junk.dat`; no strict 'vars'; eval($stuff); print $foobie; 1;

Celebrate Intellectual Diversity