Does virtualenvwrapper alter bin/activate to call the hooks?<div><br><div class="gmail_quote">On Tue, Jun 26, 2012 at 3:06 PM, Tim Saylor <span dir="ltr">&lt;<a href="mailto:tim.saylor@gmail.com" target="_blank">tim.saylor@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">If you use virtualenvwrapper then the pre- and post- activate scripts are the way to do it.  <br><br><div class="gmail_quote">
<div><div class="h5">On Sat, Jun 23, 2012 at 8:47 AM, Adam &quot;Cezar&quot; Jenkins <span dir="ltr">&lt;<a href="mailto:emperorcezar@gmail.com" target="_blank">emperorcezar@gmail.com</a>&gt;</span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">At work I&#39;m working on a new infrastructure. For various reasons, I really like how Heroku does app local settings, but can&#39;t use Heroku. They are set in the environment variables. For instance, I would use the Heroku command like so <div>


<br></div><div>heroku config:add aws_key=1234567890</div><div><br></div><div>and I could pull that in side my Django settings file with env[&#39;aws_key&#39;]</div><div><br></div><div>So I&#39;ve been wondering what the best way is to set environment variables on a per virtualenv case? So far I&#39;ve only come up with a custom activate script, or code in my Django app that updates the env dictionary using a .cfg or .yml file found in the virtualenv. I&#39;m sure there&#39;s some python or bash magic that would make it easier?</div>


<br></div></div><div class="im">_______________________________________________<br>
Chicago mailing list<br>
<a href="mailto:Chicago@python.org" target="_blank">Chicago@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/chicago" target="_blank">http://mail.python.org/mailman/listinfo/chicago</a><br>
<br></div></blockquote></div><span class="HOEnZb"><font color="#888888"><br><br clear="all"><div><br></div>-- <br>Tim Saylor<div>@tsaylor</div><div><a href="http://www.timsaylor.com/" target="_blank">http://www.timsaylor.com/</a></div>
<br>
</font></span><br>_______________________________________________<br>
Chicago mailing list<br>
<a href="mailto:Chicago@python.org">Chicago@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/chicago" target="_blank">http://mail.python.org/mailman/listinfo/chicago</a><br>
<br></blockquote></div><br></div>