getting environment variable values in 1.5.2

Kalle Svensson kalle at gnupung.net
Mon Aug 6 02:01:42 CEST 2001


Sez Rajarshi Guha:
> Hi,
>   is'nt there any function in 1.5.2 (like os.getenv in 2.1) that can
> retreive the values of specified environment variables?

Use the os.environ dictionary.  Read more on
http://www.python.org/doc/1.5.2/lib/os-procinfo.html

Peace,
  Kalle
-- 
Free Dmitry Sklyarov! - http://www.freesklyarov.org/




More information about the Python-list mailing list