feat(plugins): update plugin format to new entry_point + [[providers]] style
- owlry-core/manifest: add entry_point alias for entry field, add ProviderSpec struct for [[providers]] array, change default entry to main.lua - owlry-lua/manifest: add ProviderDecl struct and providers: Vec<ProviderDecl> for [[providers]] support - owlry-lua/loader: fall back to manifest [[providers]] when script has no API registrations; fall back to global refresh() for manifest-declared providers - owlry-lua/api: expose call_global_refresh() that calls the top-level Lua refresh() function directly - owlry/plugin_commands: update create templates to emit new format: entry_point instead of entry, [[providers]] instead of [provides], main.rn/main.lua instead of init.rn/init.lua, Rune uses Item::new() builder pattern, Lua uses standalone refresh() function - cmd_validate: accept [[providers]] declarations as a valid provides source
This commit is contained in:
@@ -50,3 +50,8 @@ pub fn call_refresh(lua: &Lua, provider_name: &str) -> LuaResult<Vec<PluginItem>
|
||||
pub fn call_query(lua: &Lua, provider_name: &str, query: &str) -> LuaResult<Vec<PluginItem>> {
|
||||
provider::call_query(lua, provider_name, query)
|
||||
}
|
||||
|
||||
/// Call the global `refresh()` function (for manifest-declared providers)
|
||||
pub fn call_global_refresh(lua: &Lua) -> LuaResult<Vec<PluginItem>> {
|
||||
provider::call_global_refresh(lua)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user