#!/usr/bin/perl $ENV{foobar} = "baz"; my $res = `echo \$foobar`; print $res; #prints 'baz'