Site-Wide Deployment of Addons

Are you missing a feature? Request it's implementation here.
yvesforkl
Posts: 13
Joined: Wed May 07, 2008 1:25 pm

Site-Wide Deployment of Addons

Post by yvesforkl » Fri Feb 05, 2021 3:49 pm

Hi,

is it possible to deploy a specific addon (in my case, a customer-specific addon hosted locally) during site-wide install, i.e. to install this addon automatically for all users of a site?

I checked the pages https://www.oxygenxml.com/doc/versions/ ... yment.html and https://www.oxygenxml.com/doc/versions/ ... d-ons.html in the XML Editor User Guide but could not find the answer.

Best regards,
Yves

alex_jitianu
Posts: 817
Joined: Wed Nov 16, 2005 11:11 am

Re: Site-Wide Deployment of Addons

Post by alex_jitianu » Mon Feb 08, 2021 1:23 pm

Hello,

Unfortunately, currently the addons can't be installed other than by user interaction. I will add a feature request for such a behavior.

An addon is basically a package that contains either a framework or a plugin.

Option 1

An administrator could run a script that copies the addons in their correct location.

- If the you intend to release new versions of the addon and the user should manually update from time to time (Oxygen presents a notification when it detects a new version), then it would be good to install these addons in the location where they normally go to. Just install one and inspect where in the user preferences it goes.

- If you don't release updates, you can skip the addon packaging altogether and deploy the plugin inside the {oxygenInstallDir}/plugins and the frameworks inside {oxygenInstallDir}/frameworks

Option 2

If the addons contains a framework you can share the framework with the Oxygen project. The idea is that the framework resides inside the project resources and every time the user loads/works inside a project the framework is automatically loaded.

Best regards,
Alex

chrispitude
Posts: 322
Joined: Thu May 02, 2019 2:32 pm

Re: Site-Wide Deployment of Addons

Post by chrispitude » Wed Feb 17, 2021 4:30 pm

Hi Alex,

Could you tell me more about option #1?

Our writers use the following Syncrosoft-developed plugins:
  • Git Client
  • DITA Prolog Updater
  • Terminology Checker (soon)
Is there a way to install these automatically for the writers via a script, such that the writers would be notified of updates in the usual way afterwards?

alex_jitianu
Posts: 817
Joined: Wed Nov 16, 2005 11:11 am

Re: Site-Wide Deployment of Addons

Post by alex_jitianu » Fri Feb 19, 2021 3:00 pm

Hi Chris,

Oxygen stores its user preferences in these locations:
- Windows - Remove the directory: %APPDATA%\Roaming\com.oxygenxml (usually %APPDATA% has the value: [user-home-dir]\Application Data). Note that this directory is hidden.
- OS X - Remove the directory: Library/Preferences/com.oxygenxml of the user home folder.
- On Linux, remove the directory: .com.oxygenxml from the user home directory.

Inside the user preferences directory there is a subdirectory named extensions. We keep the addons inside this directory, having one subdirectory for each Oxygen version: v22.0, v23.0 etc.

To prepare the addons package, you:
- delete the addons directory of your current Oxygen installation, for example v23.0
- start Oxygen and install in your Oxygen the addons that the writers should have.
- restart Oxygen to finish the installation
- zip the entire v23.0 directory

To deploy the package to the writers:
- build a script that unzips the v23.0 package to the aforementioned location: com.oxygenxml/extensions/

Let me know if there are any unclear aspects.

Best regards,
Alex

chrispitude
Posts: 322
Joined: Thu May 02, 2019 2:32 pm

Re: Site-Wide Deployment of Addons

Post by chrispitude » Tue Feb 23, 2021 4:21 pm

Alex - thank you, this makes perfect sense! I will reply back here once I am able to deploy this.

Are plugin-specific settings also stored in the addons directory? It would be even better if this method would deploy all the plugins and their required settings.

alex_jitianu
Posts: 817
Joined: Wed Nov 16, 2005 11:11 am

Re: Site-Wide Deployment of Addons

Post by alex_jitianu » Tue Feb 23, 2021 4:44 pm

Hi Chris,

Usually, plugins use our API to store options inside Oxygen global options. Can you tell me for which plugins you have changed options? Maybe the "Notify me about new commits in remote repository". Perhaps we can think of a way to provide default values for a specific plugin.

Best regards,
Alex

chrispitude
Posts: 322
Joined: Thu May 02, 2019 2:32 pm

Re: Site-Wide Deployment of Addons

Post by chrispitude » Wed Feb 24, 2021 4:18 am

Hi Alex,

We would need to specify settings for all three plugins:
  • Git Client
  • DITA Prolog Updater
  • Terminology Checker
I wonder if somehow there could be a feature, that perhaps could be configured in the Synopsys .xpr file, that would prompt the user to install certain plugins if not installed, and could copy the settings provided somehow?

Because someone technical would be setting this up, it wouldn't b a problem hand-assembling a "plugins XML" file with plugin paths, settings excepts from their own settings file, and things like that. The important part is having some kind of "plugins XML" that would automate the tasks for the novice users.

alex_jitianu
Posts: 817
Joined: Wed Nov 16, 2005 11:11 am

Re: Site-Wide Deployment of Addons

Post by alex_jitianu » Wed Feb 24, 2021 4:28 pm

Hi Chris,

The Addons preferences page can already be saved at project level. I've added an issue to specify here a set of addons to install automatically . Saving all of these at project level will meet your installation requirements. The other issue I've mentioned, the possibility to save plugin options at project level, will close the circle.

Until we implement these features, you can use the automatic installation like we've talked above. To specify options for the plugins, you can use another plugin that will import the options for all other plugins:
- first of all you start with a fresh Oxygen installation by resetting the global options. I suggest making a backup of your options before that. Both of these actions are present in the Preferences menu.
- install all required plugins. Set their options as needed.
- use the _Export global options_ action again to obtain the copy that will be imposed. The plugin options will be inside this file.

In our Maven repository we have a sample plugin that can import this options file. Unzip it and you will see a Readme file that tells you where to put the options file. This plugin, together with the options file will be the fourth plugin that you will deploy, together with the Git Client, DITA Prolog Updater and Terminology Checker.

Best regards,
Alex

Post Reply