mirror of
https://gitea.toothfairyai.com/ToothFairyAI/tf_code.git
synced 2026-03-30 05:43:55 +00:00
tweak: load user plugins after builtin (#12373)
This commit is contained in:
parent
36637b3be0
commit
1824db13cf
@ -44,12 +44,15 @@ export namespace Plugin {
|
||||
hooks.push(init)
|
||||
}
|
||||
|
||||
const plugins: string[] = []
|
||||
const plugins = []
|
||||
if (!Flag.OPENCODE_DISABLE_DEFAULT_PLUGINS) {
|
||||
plugins.push(...BUILTIN)
|
||||
}
|
||||
plugins.push(...(config.plugin ?? []))
|
||||
if (plugins.length) await Config.waitForDependencies()
|
||||
if (config.plugin) {
|
||||
plugins.push(...config.plugin)
|
||||
}
|
||||
const wait = Flag.OPENCODE_DISABLE_DEFAULT_PLUGINS ? plugins.length : plugins.length > BUILTIN.length
|
||||
if (wait) await Config.waitForDependencies()
|
||||
|
||||
for (let plugin of plugins) {
|
||||
// ignore old codex plugin since it is supported first party now
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user