I'm on a Windows 7 machine with QGIS 2.8 installed via OSGeo4W. I'm developing several processing scripts that make use of a few common pieces of code. Rather than maintain the code in each individual script file, I'd like to import the common functions into each script.
These scripts may be shared between multiple users so I'd like to avoid having code stored in multiple locations. My initial thought was to save _foo.py within the .qgis2\processing\scripts folder on my user account and then import via
import _foo
However, Processing doesn't set the scripts directory as the CWD of the python interpreter so the utility script doesn't get picked up.
Is there a way to achieve my goal without turning this into a full-blown QGIS plugin?