I have both ArcGIS 10.1 and QGIS 1.8 installed and both include Python 2.7 in slightly different setups and in different folders (c:\Python27\ArcGIS10.1\ and c:\Program Files (x86)\Quantum GIS Lisboa\apps\Python27).
It is only ArcGIS Desktop which include python.exe, while it is really QGIS I would like to start experimenting with for some scripting, but preferably just running my scripts from the command console.
How do I do this?
I'm thinking of settings environment variables etc.
I am new to both QGIS and Python.
Best Answer
While you can do it with the standalone installed copy of QGIS I would highly recommend installing QGIS and QGIS-dev using the OSGeo4W installer. OSGeo is easier to update and lets you get the latest stuff.
That will install Python into
C:\OSGeo4W\app\Python27
and let you run Python from the OSGeo4W shell.python.exe
lives inC:\OSGeo4W\bin
.I have some examples of QGIS stuff at https://github.com/NathanW2/pyqgis-playground
Use the following batch file as a bootstrap to your python file: