diff --git a/examples/miniapps/movie-lister/setup_and_run_movie_lister.bat b/examples/miniapps/movie-lister/setup_and_run_movie_lister.bat index 6c6b942b..8f20daf0 100644 --- a/examples/miniapps/movie-lister/setup_and_run_movie_lister.bat +++ b/examples/miniapps/movie-lister/setup_and_run_movie_lister.bat @@ -1,11 +1,22 @@ echo on -set PYTHON37=%UserProfile%\AppData\Local\Programs\Python\Python37\python.exe +REM The assumption is made that the python executable can be found. -REM set variabless +REM Set variabless set ENV_NAME=wslenv2-win set VENV_DIR=%ENV_NAME%\Scripts set PYTHON_VENV=%VENV_DIR%\python.exe -%PYTHON37% -m venv %ENV_NAME% +REM Create virtual environment +python -m venv %ENV_NAME% + +REM Populate dependencies and run the example +Start /WAIT cmd /k "%VENV_DIR%\activate&^ +%PYTHON_VENV% -m pip install --upgrade pip&^ +%PYTHON_VENV% -m pip install -r .\requirements.txt&^ +set MOVIE_FINDER_TYPE=csv&^ +%PYTHON_VENV% -m movies&^ +set MOVIE_FINDER_TYPE=sqlite&^ +%PYTHON_VENV% -m movies&^ +%VENV_DIR%\deactivate&^ +pause -Start /WAIT cmd /k "%VENV_DIR%\activate & %PYTHON_VENV% -m pip install --upgrade pip & %PYTHON_VENV% -m pip install -r .\requirements.txt & set MOVIE_FINDER_TYPE=csv& %PYTHON_VENV% -m movies & set MOVIE_FINDER_TYPE=sqlite& %PYTHON_VENV% -m movies&%VENV_DIR%\deactivate & pause & exit 0"