Theia: [plugins] reference multiple plugin directories when using the cli argument

Created on 29 Jan 2020  路  9Comments  路  Source: eclipse-theia/theia

Description


Is it possible to add another folder to --plugins? like a secondary folder? something like?

yarn theia start --plugins=local-dir:../../plugins:../../../another-plugins-folder

enhancement help wanted plug-in system

Most helpful comment

@akosyakov env variables make a lot of sense in container, where you don't have more than one installation of Theia. For me locally, I typically have multiple ones (dev tool and target). What I'm trying to say is I am +1 on adding multi-folder to the cli.

All 9 comments

From what I can tell from the source code only a single directory can be referenced using the cli option. If so, I think it might be a useful improvement to lookup from a list of directories instead.

Perhaps @eclipse-theia/plugin-system may have some more information.

We could improve to allow either to pass --plugins option multiple times or comma separated values.

You also can use an env variable instead right now which supports comma separated values: https://github.com/eclipse-theia/theia/blob/049fb524480292274131c0f888e82a9fbaa7878f/packages/plugin-ext/src/main/node/plugin-deployer-impl.ts#L92-L105

I didn't now that there was a global variable. Now it make sense, a global plugins dir set through THEIA_DEFAULT_PLUGINS or THEIA_PLUGINS and a local specific to project in --plugins

@akosyakov env variables make a lot of sense in container, where you don't have more than one installation of Theia. For me locally, I typically have multiple ones (dev tool and target). What I'm trying to say is I am +1 on adding multi-folder to the cli.

I have another suggestion can separate the folders with ":" instead ","? To be consistent with PATH variable?

hi, I don't think it might work for : as value can contain protocol/link like
local-dir:///tmp

if split is around : it will break

Should be system path separator, not fixed ':'

yes you are right. Forgot about local-dir

I think it should be:
yarn theia start --plugins=../../plugins --plugins../../../another-plugins-folder

without any separators

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tetchel picture tetchel  路  3Comments

akosyakov picture akosyakov  路  3Comments

jeanlucburot picture jeanlucburot  路  3Comments

kpge picture kpge  路  3Comments

Beetix picture Beetix  路  3Comments