activate.bat 973 B

123456789101112131415161718192021222324252627282930313233
  1. @echo off
  2. rem This file is UTF-8 encoded, so we need to update the current code page while executing it
  3. for /f "tokens=2 delims=:." %%a in ('"%SystemRoot%\System32\chcp.com"') do (
  4. set _OLD_CODEPAGE=%%a
  5. )
  6. if defined _OLD_CODEPAGE (
  7. "%SystemRoot%\System32\chcp.com" 65001 > nul
  8. )
  9. set VIRTUAL_ENV=D:\Future\Slash\OpenISP\Backend\venv
  10. if not defined PROMPT set PROMPT=$P$G
  11. if defined _OLD_VIRTUAL_PROMPT set PROMPT=%_OLD_VIRTUAL_PROMPT%
  12. if defined _OLD_VIRTUAL_PYTHONHOME set PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%
  13. set _OLD_VIRTUAL_PROMPT=%PROMPT%
  14. set PROMPT=(venv) %PROMPT%
  15. if defined PYTHONHOME set _OLD_VIRTUAL_PYTHONHOME=%PYTHONHOME%
  16. set PYTHONHOME=
  17. if defined _OLD_VIRTUAL_PATH set PATH=%_OLD_VIRTUAL_PATH%
  18. if not defined _OLD_VIRTUAL_PATH set _OLD_VIRTUAL_PATH=%PATH%
  19. set PATH=%VIRTUAL_ENV%\Scripts;%PATH%
  20. :END
  21. if defined _OLD_CODEPAGE (
  22. "%SystemRoot%\System32\chcp.com" %_OLD_CODEPAGE% > nul
  23. set _OLD_CODEPAGE=
  24. )