Framework extension and dependencies

Post here questions and problems related to oXygen frameworks/document types.
Krille
Posts: 33
Joined: Thu Nov 12, 2020 12:24 pm

Framework extension and dependencies

Post by Krille »

Hi,

I've already developed an author mode extension for TEI editing last year. Now, there are several new projects and their needs differ, e.g. regarding the script direction (left-to-right or right-to-left), so that different CSSs are needed, or templates and transformation scenarios are different etc.

So several extensions are needed that are all based on the TEI P5 framework and all of them share a common codebase of author mode actions (exported to files already). However, all add project-specific functions.

I'd like to develop a base extension named teip5scdh based on TEI P5, and then develop project specific extensions teip5projN (where N=1..n) each based on teip5scdh.

My question is: Is there a dependency management, so that if I choose to install, say, teip5proj2, then teip5scdh is automatically installed (and in the version, that is required by teip5proj2)?

Or should I try to integrate the dependency framework into the zip-file of the project-specific framework, i.e. packaging file paths frameworks/teip5scdh and frameworks/teip5proj2 into the same zip? Going this way, will a user run into problems, if he installs teip5proj1 AND teip5proj2, so that in effect he has installed teip5scdh several times?

BTW, where is that compileFrameworkExtension script, which is new in Version 23?

Regards,
Christian
alex_jitianu
Posts: 1007
Joined: Wed Nov 16, 2005 11:11 am

Re: Framework extension and dependencies

Post by alex_jitianu »

Hello Christian,
My question is: Is there a dependency management, so that if I choose to install, say, teip5proj2, then teip5scdh is automatically installed (and in the version, that is required by teip5proj2)?
Unfortunately, we don't have such a dependency mechanism yet. We do have a feature request recorded and I will add your vote for it.
Or should I try to integrate the dependency framework into the zip-file of the project-specific framework, i.e. packaging file paths frameworks/teip5scdh and frameworks/teip5proj2 into the same zip? Going this way, will a user run into problems, if he installs teip5proj1 AND teip5proj2, so that in effect he has installed teip5scdh several times?
If the add-on archive contains multiple root folders, only one of them that contains a *.framework file is kept. I can think of a way to bring them both, through an Additional frameworks plugin, but you might have troubles along the way. If you install teip5scdh several times, only one of instance will be loaded and you can't control which. If teip5proj1 depends on teip5scdh_version1 and teip5proj2 depends on teip5scdh_version2, then there might be problems since only one version of teip5scdh gets loaded.

A possible solution would be to distribute the frameworks inside Oxygen projects, teip5ProjectN (where N=1..n). Each one will contain the teip5scdh base framework and a specific teip5projN framework.
BTW, where is that compileFrameworkExtension script, which is new in Version 23?
The script is available only in the All platforms distribution.

Best regards,
Alex
Post Reply