Creating and sharing a 'utils.py' file across tools

I have multiple tools created using pyRevit. However, a few of these tools use common functions I have written. I tried setting up the extension as a Python package to potentially share these functions, but this was to no avail. Are there any tips or suggestions for setting this up relatively easily? Or is the approach to create a custom pyRevit clone that contains my library package (I’d like to avoid this)?

1 Like

Create a lib/ directory inside your extension and place your shared modules there. See

1 Like

Brilliant. Thank you. I don’t know how I didn’t see that in the docs :man_facepalming:.

1 Like