I found this post to be useful on how to code a batch file to automate django web server start.
But the problem is, there is no virtualenv activated, How can i activate it before the manage.py runserver inside the script?
I found this post to be useful on how to code a batch file to automate django web server start.
But the problem is, there is no virtualenv activated, How can i activate it before the manage.py runserver inside the script?
 
    
     
    
    Found my solution by encoding this:
@echo off
cmd /k "cd /d C:\Users\[user]\path\to\your\env\scripts & activate & cd /d C:\Users\[user]\path\to\your\env\[projectname] & python manage.py runserver"
 
    
    Call the activate.bat script in your batch file, before you run manage.py,
CALL \path\to\env\Scripts\activate.bat
python manage.py runserver
 
    
    try \path\to\env\Scripts\activate
and look at virtualenv docs
 
    
    If your virtualenv is created via virtualenvwrapper:
workon yourenvname & python manage.py runserver