I am using QGIS 2.18.3 to create an atlas. This works well and I now want to call some functions to create richer content in a text box. To do this I am calling a python function from an expression. Works fine.

Since I am working on several computers I would like to keep track of my python code. I am using GitHub for this. However - QGIS takes a global approach and by default places my code in this folder (yes using Windows):


I would like to keep the python code related to this project relative to this particular QGIS project file. This way I will be able to keep track of the functions relevant to this particular project. Is this possible?

  • I think this post might be related: Is it possible to distribute custom python expressions along with .qgs file? – Joseph Feb 16 '17 at 14:00
  • Agree the posting is related. What I am hoping is that this path can somehow be set (or reset) in some way. A script that does this when the project opens would be elegant. – ragnvald Feb 16 '17 at 14:05
  • The variable/path is set somewhere. It is however not available/stated under the variables overview in the expression editor. Being able to append a path would be of great help. – ragnvald Mar 1 '17 at 18:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.