I have created a plugin consisting of a set of python scripts. Some of these scripts are linked to commands that create specific objects, and other scripts are linked to commands that should export these objects to a custom format that I need for importing the objects into another software (some finite element software).
The way I export these objects is that I open a template input file that contains not objects, but still a lot of software-related stuff such as settings and other stuff. At the corresponding sections of that input file I insert my objects and then save it under a new name.
The problem is that I don’t know how to distribute this template file with the plugin, which I tried to package with a .rhi file. Just copying it to the root directory of the .rhi archive the script cannot find it (it’s looking at “…Program Files/Rhinoceros 5 (64-bit)/System”. How can I provide a relative path to the Install folder of the plugin?
points to “…\Program Files\Rhinoceros 5 (64-bit)\Plug-ins\IronPython”
To package the plugin I zipped all files (including the template input file) and changed the extension to rhi. The archive is installed to “…Program Files\Common Files\McNeel\Rhinoceros\5.0\Plug-ins\PythonPlugins”. This would be the path that I’d like to reference (I don’t need to write to the same location).