This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Perl and the fly likes environment variable Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Languages » Perl
Bookmark "environment variable" Watch "environment variable" New topic
Author

environment variable

anandkumar biyani
Greenhorn

Joined: Dec 06, 2011
Posts: 9
Hello,

I wanted to use path to a file in my perl script, so want to store this path in some environment variable and than use this variable as input to my script.

Can anyone help how to create environment variable and use this as a input to my script

Thanks in advance.
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 11170
    
  16

anandkumar biyani wrote:Hello,

I wanted to use path to a file in my perl script, so want to store this path in some environment variable and than use this variable as input to my script.

Can anyone help how to create environment variable and use this as a input to my script

Thanks in advance.

Creating an environment variable depends on your OS.

To use an environment variable, you can just use the %ENV hash...something like



There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: environment variable
 
Similar Threads
javac
getting and setting environment variables
How to start Tomcat?
Classpath problem
classpath and jdbc