intellij python global environment set fail
<p>I set some environment variables in /etc/profile or .bashrc ,all can not be use in intellij with python when runtime. 
so I have to set those variables in in intellij in here bellow.
<a href="http://i.stack.imgur.com/P47B9.png" rel="nofollow">idea set global environment variables for all projects</a></p>

<p>however, i run a script code like this :</p>

<pre><code>import os
print os.environ['PYTHONUNBUFFERED'] # intellij auto set ,work fine
print os.environ['CUDA_HOME']` # i set , failed, key_error.
</code></pre>

<p>the output surprised me. 
they both be set in the same place and same format. but behave different.</p>

<p>anyone can explain? thanks.</p>

<p>Setting environment variables in <code>.bashrc</code> make them relative to one user's session only.</p>

<p>And <code>/etc/profile</code> limit env variables to the shell.</p>

<p>Set your variables in : <code>/etc/environment</code> or <code>/etc/security/pam_env.conf</code></p>

<p>See : <a href="http://www.linux-pam.org/Linux-PAM-html/sag-pam_env.html" rel="nofollow">http://www.linux-pam.org/Linux-PAM-html/sag-pam_env.html</a></p>

python intellij-idea environment-variables