Using Bash environment variables from within a Perl script?

Viewed 1848

I am trying to run a Bash command from within my Perl program. However Perl seems to be confusing my Bash $PWD environment variable as a Perl variable.

How can I make it just read it all as a string?

This is what I'm trying to run

my $path = /first/path;
`ln -s $path $PWD/second/path`

Those backticks runs the second line in Bash. Using System() produces the same problem.

Any ideas?

1 Answers
Related