*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> perl5/Env (3)              
Title
Content
Arch
Section
 

Contents


Env(3)									Env(3)


NAME    [Toc]    [Back]

     Env - perl	module that imports environment	variables

SYNOPSIS    [Toc]    [Back]

	 use Env;
	 use Env qw(PATH HOME TERM);

DESCRIPTION    [Toc]    [Back]

     Perl maintains environment	variables in a pseudo-hash named %ENV.	For
     when this access method is	inconvenient, the Perl module Env allows
     environment variables to be treated as simple variables.

     The Env::import() function	ties environment variables with	suitable names
     to	global Perl variables with the same names.  By default it does so with
     all existing environment variables	(keys %ENV).  If the import function
     receives arguments, it takes them to be a list of environment variables
     to	tie; it's okay if they don't yet exist.

     After an environment variable is tied, merely use it like a normal
     variable.	You may	access its value

	 @path = split(/:/, $PATH);

     or	modify it

	 $PATH .= ":.";

     however you'd like.  To remove a tied environment variable	from the
     environment, assign it the	undefined value

	 undef $PATH;

AUTHOR    [Toc]    [Back]

     Chip Salzenberg <chip@fin.uucp>


									PPPPaaaaggggeeee 1111
[ Back ]
 Similar pages
Name OS Title
env Tru64 Displays or sets the current environment, or displays the values of environment variables
printenv Tru64 Displays or sets the current environment, or displays the values of environment variables
dtenvvar HP-UX CDE environment variables
pxfclearenv IRIX Clears all environment variables
pe_environ IRIX Programming environment variables
pam_getenvlist FreeBSD returns a list of all the PAM environment variables
perlvar OpenBSD Perl predefined variables
perlvar IRIX Perl predefined variables
consvar Tru64 Manipulate system firmware console environment variables
intro Tru64 Introduction to kernel module routines, data structures, and global variables
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service