Skip to content

Instantly share code, notes, and snippets.

@iesmatauw
Forked from zvodd/envpython.bat
Last active August 29, 2015 14:16
Show Gist options
  • Save iesmatauw/c36240445246b2478b39 to your computer and use it in GitHub Desktop.
Save iesmatauw/c36240445246b2478b39 to your computer and use it in GitHub Desktop.

Revisions

  1. @zvodd zvodd revised this gist Feb 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion envpython.bat
    Original file line number Diff line number Diff line change
    @@ -4,7 +4,7 @@ REM https://docs.python.org/2/using/windows.html for more info around the subjec

    REM set PythonDIR to your python 2 or 3 install path; e.g. the folder with python.exe in it.

    set PythonDIR="C:\Python27"
    set PythonDIR=C:\Python27
    set PATH=%PythonDIR%;%PythonDIR%\Scripts;%PATH%
    set PYTHONPATH=%PythonDIR%\Lib;%PythonDIR%\Lib\site-packages;%PythonDIR%\DLLs;
    set PATHEXT=%PATHEXT%;.PY;.PYW
  2. @zvodd zvodd revised this gist Feb 25, 2015. 1 changed file with 4 additions and 2 deletions.
    6 changes: 4 additions & 2 deletions envpython.bat
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,9 @@
    @echo off
    REM "ftype /?" explains all of this assoc and ftype and PATHEXT usage
    REM https://docs.python.org/2/using/windows.html for more info around the subject.

    REM set PythonDIR to your python 2 or 3 install path; e.g. the folder with python.exe in it.

    set PythonDIR="C:\Python27"
    set PATH=%PythonDIR%;%PythonDIR%\Scripts;%PATH%
    set PYTHONPATH=%PythonDIR%\Lib;%PythonDIR%\Lib\site-packages;%PythonDIR%\DLLs;
    @@ -8,5 +12,3 @@ assoc .py=Python.File >NUL
    assoc .pyw=PythonW.File >NUL
    ftype Python.File=%PythonDIR%\python.exe "%%1" %%* >NUL
    ftype PythonW.File=%PythonDIR%\pythonw.exe "%%1" %%* >NUL
    REM "ftype /?" explains all of this assoc and ftype and PATHEXT usage
    REM https://docs.python.org/2/using/windows.html for more info around the subject.
  3. @zvodd zvodd revised this gist Feb 25, 2015. 1 changed file with 6 additions and 4 deletions.
    10 changes: 6 additions & 4 deletions envpython.bat
    Original file line number Diff line number Diff line change
    @@ -4,7 +4,9 @@ set PythonDIR="C:\Python27"
    set PATH=%PythonDIR%;%PythonDIR%\Scripts;%PATH%
    set PYTHONPATH=%PythonDIR%\Lib;%PythonDIR%\Lib\site-packages;%PythonDIR%\DLLs;
    set PATHEXT=%PATHEXT%;.PY;.PYW
    assoc .py=Python.File
    assoc .pyw=PythonW.File
    ftype Python.File=%PythonDIR%\python.exe "%1" %*
    ftype PythonW.File=%PythonDIR%\pythonw.exe "%1" %*
    assoc .py=Python.File >NUL
    assoc .pyw=PythonW.File >NUL
    ftype Python.File=%PythonDIR%\python.exe "%%1" %%* >NUL
    ftype PythonW.File=%PythonDIR%\pythonw.exe "%%1" %%* >NUL
    REM "ftype /?" explains all of this assoc and ftype and PATHEXT usage
    REM https://docs.python.org/2/using/windows.html for more info around the subject.
  4. @zvodd zvodd revised this gist Feb 25, 2015. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion envpython.bat
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,6 @@
    @echo off
    REM set PythonDIR to your python 2 or 3 install path; e.g. the folder with python.exe in it.
    set PythonDIR=C:\Python27
    set PythonDIR="C:\Python27"
    set PATH=%PythonDIR%;%PythonDIR%\Scripts;%PATH%
    set PYTHONPATH=%PythonDIR%\Lib;%PythonDIR%\Lib\site-packages;%PythonDIR%\DLLs;
    set PATHEXT=%PATHEXT%;.PY;.PYW
  5. @zvodd zvodd created this gist Feb 25, 2015.
    10 changes: 10 additions & 0 deletions envpython.bat
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    @echo off
    REM set PythonDIR to your python 2 or 3 install path; e.g. the folder with python.exe in it.
    set PythonDIR=C:\Python27
    set PATH=%PythonDIR%;%PythonDIR%\Scripts;%PATH%
    set PYTHONPATH=%PythonDIR%\Lib;%PythonDIR%\Lib\site-packages;%PythonDIR%\DLLs;
    set PATHEXT=%PATHEXT%;.PY;.PYW
    assoc .py=Python.File
    assoc .pyw=PythonW.File
    ftype Python.File=%PythonDIR%\python.exe "%1" %*
    ftype PythonW.File=%PythonDIR%\pythonw.exe "%1" %*