I have this bat file in a directory in PATH (For me this is C:\bin\osgeo-py3.bat). I run it in a command session after running Osgeo4W.bat. After this you don't need to use the `python path\to\file.py`invocation.
::: set PATH=%PATH%;%OSGEO4W_ROOT%\apps\Python37;%OSGEO4W_ROOT%\apps\Python37\Scripts set PYTHONHOME=%OSGEO4W_ROOT%\apps\Python37 ::: You could put it in Osgeo4W.bat and save yourself a step but it will be clobbered on every upgrade. It's not set by default now because of needing to support python 2 & 3 at the same time. (Aside: It's pretty cool to see that the simple script I wrote a zillion years ago to "OSGeo4W creates .bat file for each Python script." is still used and working. Thanks for the kind words Jukka.) ----- -Matt -- Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html _______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev