feat: tracatch plugin build
Signed-off-by: MiaoWoo <admin@yumc.pw>
This commit is contained in:
parent
39861b2c46
commit
ace2c48ae2
@ -8,8 +8,8 @@
|
||||
"scripts": {
|
||||
"bs": "lerna bootstrap",
|
||||
"clean": "lerna run clean",
|
||||
"watch": "lerna run watch --parallel --scope=\"@ms/!(manager)\"",
|
||||
"build": "lerna run build --scope=\"@ms/!(plugins|manager)\"",
|
||||
"watch": "lerna run watch --parallel",
|
||||
"build": "lerna run build --scope=\"@ms/!(plugins)\"",
|
||||
"build:plugins": "lerna run build --scope=\"@ms/plugins\"",
|
||||
"ug": "yarn upgrade-interactive --latest",
|
||||
"lp": "lerna publish"
|
||||
|
@ -186,6 +186,7 @@ export class PluginManagerImpl implements plugin.PluginManager {
|
||||
}
|
||||
|
||||
private buildPlugin(metadata: interfaces.PluginMetadata) {
|
||||
try {
|
||||
this.bindPlugin(metadata)
|
||||
let pluginInstance = this.container.getNamed<interfaces.Plugin>(plugin.Plugin, metadata.name)
|
||||
if (!(pluginInstance instanceof interfaces.Plugin)) {
|
||||
@ -193,7 +194,11 @@ export class PluginManagerImpl implements plugin.PluginManager {
|
||||
return
|
||||
}
|
||||
this.pluginMap.set(metadata.name, pluginInstance)
|
||||
return pluginInstance
|
||||
return pluginInstance;
|
||||
} catch (ex) {
|
||||
console.i18n("ms.plugin.manager.initialize.error", { name: metadata.name, ex })
|
||||
console.ex(ex)
|
||||
}
|
||||
}
|
||||
|
||||
private bindPlugin(metadata: interfaces.PluginMetadata) {
|
||||
|
Loading…
Reference in New Issue
Block a user