I am using virtualenvwrapper-win and want to use the postactivate hook virtualenvwrapper to set environment variables. However, virtualenvwrapper-win does not seem to include the postactivate file, and I could not get it working by creating my own. Does anyone know how to make postactivate hook work with virtualenvwrapper-win?
I want to include this in postactivate to set the environment variable: SET APP_SETTINGS="example.setting"
SET APP_SETTINGS="example.setting"
I really decided it myself. You can put any environment variables in the activate.bat file in the Scripts folder of your virtualenv.
If you have already defined your VIRTUALENVWRAPPER_HOOK_DIR variable, just add this line to workon.bat .
VIRTUALENVWRAPPER_HOOK_DIR
workon.bat
call "%VIRTUALENVWRAPPER_HOOK_DIR%\postactivate.bat"
Just make sure you put it higher :END
:END
Source: https://habr.com/ru/post/979814/More articles:Performance of virtual functions when called by derived classes? - c ++How to debug cordova plugin and log using "android.util.log" - javaHow can I transfer a video using ASP.NET MVC? - c #How to achieve transitions without blurring text in Webkit due to hardware acceleration - cssIs there a non-recursive way to write this paginate function? - haskellDoes ngChange not work when the model changes programmatically? - javascripthttps://translate.googleusercontent.com/translate_c?depth=1&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/979816/gaining-access-to-package-access-members-by-creating-the-same-package-name&usg=ALkJrhgeU2dTS-gCmmD2taoRmwOF1HcP_ACan JMSI18nRoutingBundle use an Accept-Language HTTP array? - internationalizationUsing the C # MongoDB Driver, how to serialize a collection of referee objects? - referenceCopy unsigned folder to another branch - gitAll Articles