set environmental variable from python

Alexander Blinne news at blinne.net
Sat Nov 1 12:30:14 EDT 2014


Am 31.10.2014 um 02:22 schrieb Artur Bercik:
> I have to set environmental variable in my windows PC as follows:
> 
> variable name: GISBASE
> 
> value: C:\GRASS-64
> 
> Is it possible to set it from python?
> 
> import sys
> 
> sys.path.append("C:\\GRASS-64")
> 
> But how to give variable name? I have to set both the variable name and
> value.

http://lmgtfy.com/?q=how+to+set+environment+variable+with+python




More information about the Python-list mailing list